aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/environment.py
diff options
context:
space:
mode:
Diffstat (limited to 'mesonbuild/environment.py')
-rw-r--r--mesonbuild/environment.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py
index 9830b45..bf75c80 100644
--- a/mesonbuild/environment.py
+++ b/mesonbuild/environment.py
@@ -55,6 +55,7 @@ from .linkers import (
GnuBFDDynamicLinker,
GnuGoldDynamicLinker,
LLVMDynamicLinker,
+ QualcommLLVMDynamicLinker,
MSVCDynamicLinker,
OptlinkDynamicLinker,
PGIDynamicLinker,
@@ -1028,10 +1029,13 @@ class Environment:
check_args += override
_, o, e = Popen_safe(compiler + check_args)
- v = search_version(o)
+ v = search_version(o + e)
if o.startswith('LLD'):
linker = LLVMDynamicLinker(
compiler, for_machine, comp_class.LINKER_PREFIX, override, version=v) # type: DynamicLinker
+ elif 'Snapdragon' in e and 'LLVM' in e:
+ linker = QualcommLLVMDynamicLinker(
+ compiler, for_machine, comp_class.LINKER_PREFIX, override, version=v) # type: DynamicLinker
elif e.startswith('lld-link: '):
# The LLD MinGW frontend didn't respond to --version before version 9.0.0,
# and produced an error message about failing to link (when no object
@@ -1227,7 +1231,7 @@ class Environment:
return cls(
compiler, version, for_machine, is_cross, info, exe_wrap,
target, linker=linker)
- if 'clang' in out:
+ if 'clang' in out or 'Clang' in out:
linker = None
defines = self.get_clang_compiler_defines(compiler)