diff --git a/mesonbuild/compilers/mixins/clang.py b/mesonbuild/compilers/mixins/clang.py index 41b35c041336..82df325ec01e 100644 --- a/mesonbuild/compilers/mixins/clang.py +++ b/mesonbuild/compilers/mixins/clang.py @@ -187,7 +187,7 @@ def get_lto_compile_args(self, *, threads: int = 0, mode: str = 'default') -> T. def linker_to_compiler_args(self, args: T.List[str]) -> T.List[str]: if isinstance(self.linker, (ClangClDynamicLinker, MSVCDynamicLinker)): - return [flag if flag.startswith('-Wl,') else f'-Wl,{flag}' for flag in args] + return [flag if flag.startswith('-Wl,') or flag.startswith('-fuse-ld=') else f'-Wl,{flag}' for flag in args] else: return args