diff options
author | Nirbheek Chauhan <nirbheek@centricular.com> | 2019-03-12 17:56:44 +0530 |
---|---|---|
committer | Nirbheek Chauhan <nirbheek.chauhan@gmail.com> | 2019-03-14 12:21:05 +0000 |
commit | 07818dac6acc7a805548be4b605320dd27de126c (patch) | |
tree | 768d8eff8970d3c51312153ea0426660f11c9779 /mesonbuild/compilers/c.py | |
parent | 5f00c3020073962edbeb2f3f709c27acdb09fd74 (diff) | |
download | meson-07818dac6acc7a805548be4b605320dd27de126c.zip meson-07818dac6acc7a805548be4b605320dd27de126c.tar.gz meson-07818dac6acc7a805548be4b605320dd27de126c.tar.bz2 |
compilers: Try harder to dedup builtin libs
Compiler internal libs should always be de-duplicated, no matter what.
Closes https://github.com/mesonbuild/meson/issues/2150
Test case is by Bruce Richardson in the issue.
Diffstat (limited to 'mesonbuild/compilers/c.py')
-rw-r--r-- | mesonbuild/compilers/c.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/mesonbuild/compilers/c.py b/mesonbuild/compilers/c.py index d4626d6..d4d6f66 100644 --- a/mesonbuild/compilers/c.py +++ b/mesonbuild/compilers/c.py @@ -35,6 +35,7 @@ from .compilers import ( get_largefile_args, gnu_winlibs, msvc_winlibs, + unixy_compiler_internal_libs, vs32_instruction_set_args, vs64_instruction_set_args, ArmCompiler, @@ -52,8 +53,6 @@ from .compilers import ( CcrxCompiler, ) -gnu_compiler_internal_libs = ('m', 'c', 'pthread', 'dl', 'rt') - class CCompiler(Compiler): # TODO: Replace this manual cache with functools.lru_cache @@ -61,7 +60,7 @@ class CCompiler(Compiler): program_dirs_cache = {} find_library_cache = {} find_framework_cache = {} - internal_libs = gnu_compiler_internal_libs + internal_libs = unixy_compiler_internal_libs @staticmethod def attribute_check_func(name): @@ -1375,7 +1374,7 @@ class IntelCCompiler(IntelCompiler, CCompiler): class VisualStudioCCompiler(CCompiler): std_warn_args = ['/W3'] std_opt_args = ['/O2'] - ignore_libs = gnu_compiler_internal_libs + ignore_libs = unixy_compiler_internal_libs internal_libs = () crt_args = {'none': [], |