diff options
| author | Frankie Robertson <frankie@robertson.name> | 2025-11-17 12:40:19 +0200 |
|---|---|---|
| committer | Dylan Baker <dylan@pnwbakers.com> | 2025-11-19 08:16:19 -0800 |
| commit | c6341fcd56a704973b24626def6111d1a6547542 (patch) | |
| tree | d3b1a2d75aaf547f64b675c8aa65d3d4e05a42c0 | |
| parent | be0a3448aa63adbe8a949c8f9f8c615d24c1d8d1 (diff) | |
| download | meson-c6341fcd56a704973b24626def6111d1a6547542.tar.gz | |
Prevent /link being passed twice in compiler flags
This does not work correctly with clang-cl/lld-link
| -rw-r--r-- | mesonbuild/compilers/mixins/visualstudio.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/compilers/mixins/visualstudio.py b/mesonbuild/compilers/mixins/visualstudio.py index 746f59395..6d9b7ac7b 100644 --- a/mesonbuild/compilers/mixins/visualstudio.py +++ b/mesonbuild/compilers/mixins/visualstudio.py @@ -188,7 +188,7 @@ class VisualStudioLikeCompiler(Compiler, metaclass=abc.ABCMeta): return args def linker_to_compiler_args(self, args: T.List[str]) -> T.List[str]: - return ['/link'] + args + return ['/link'] + [arg for arg in args if arg != '/link'] def get_pic_args(self) -> T.List[str]: return [] # PIC is handled by the loader on Windows |
