summaryrefslogtreecommitdiff
path: root/mesonbuild/compilers
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2025-02-13 16:39:40 +0100
committerDylan Baker <dylan@pnwbakers.com>2025-04-02 08:44:37 -0700
commitdfefd838a846dd944d8a3f91200b6c54f0ffd198 (patch)
treef9c2374d04dc5b545f92bc25135e031e00c73abd /mesonbuild/compilers
parent7875bc226137c07ae7b8c3678bfb76999984b627 (diff)
downloadmeson-dfefd838a846dd944d8a3f91200b6c54f0ffd198.tar.gz
ninjabackend: split out generation of rustc arguments
Allow reusing the code for doctests. In particular, the sources are shared between the two cases. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'mesonbuild/compilers')
-rw-r--r--mesonbuild/compilers/rust.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/mesonbuild/compilers/rust.py b/mesonbuild/compilers/rust.py
index 011c28f1d..210544ed8 100644
--- a/mesonbuild/compilers/rust.py
+++ b/mesonbuild/compilers/rust.py
@@ -279,6 +279,8 @@ class RustCompiler(Compiler):
def get_linker_always_args(self) -> T.List[str]:
args: T.List[str] = []
+ # Rust is super annoying, calling -C link-arg foo does not work, it has
+ # to be -C link-arg=foo
for a in super().get_linker_always_args():
args.extend(['-C', f'link-arg={a}'])
return args