aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/dependencies/boost.py
diff options
context:
space:
mode:
authorJon Turney <jon.turney@dronecode.org.uk>2018-09-20 20:29:57 +0100
committerJon Turney <jon.turney@dronecode.org.uk>2018-11-04 15:42:00 +0000
commit64edfd50691be21fae1e61b8864d6de6fcead1d4 (patch)
treeedff913b3cc3fa1adf558e1b1c860aad8f7a7717 /mesonbuild/dependencies/boost.py
parent63f4f9481ebc865b11a06aeecf0c624104d46afd (diff)
downloadmeson-64edfd50691be21fae1e61b8864d6de6fcead1d4.zip
meson-64edfd50691be21fae1e61b8864d6de6fcead1d4.tar.gz
meson-64edfd50691be21fae1e61b8864d6de6fcead1d4.tar.bz2
Detect clang-cl as msvc-like, not clang-like
Handle clang's cl or clang-cl being in PATH, or set in CC/CXX Future work: checking the name of the executable here seems like a bad idea. These compilers will fail to be detected if they are renamed. v2: Update compiler.get_argument_type() test Fix comparisons of id inside CCompiler, backends and elsewhere v3: ClangClCPPCompiler should be a subclass of ClangClCCompier, as well Future work: mocking in test_find_library_patterns() is effected, as we now test for a subclass, rather than self.id in CCompiler.get_library_naming()
Diffstat (limited to 'mesonbuild/dependencies/boost.py')
-rw-r--r--mesonbuild/dependencies/boost.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/mesonbuild/dependencies/boost.py b/mesonbuild/dependencies/boost.py
index 17f9240..6a8050d 100644
--- a/mesonbuild/dependencies/boost.py
+++ b/mesonbuild/dependencies/boost.py
@@ -288,7 +288,7 @@ class BoostDependency(ExternalDependency):
tag = None
compiler = self.env.detect_cpp_compiler(self.want_cross)
if mesonlib.for_windows(self.want_cross, self.env):
- if compiler.get_id() == 'msvc':
+ if compiler.get_id() in ['msvc', 'clang-cl']:
comp_ts_version = compiler.get_toolset_version()
compiler_ts = comp_ts_version.split('.')
# FIXME - what about other compilers?
@@ -320,7 +320,7 @@ class BoostDependency(ExternalDependency):
def arch_tag(self):
# currently only applies to windows msvc installed binaries
- if self.env.detect_cpp_compiler(self.want_cross).get_id() != 'msvc':
+ if self.env.detect_cpp_compiler(self.want_cross).get_id() not in ['msvc', 'clang-cl']:
return ''
# pre-compiled binaries only added arch tag for versions > 1.64
if float(self.version) < 1.65: