u-rustc-llvm-cross-flags
authorDebian Rust Maintainers <pkg-rust-maintainers@alioth-lists.debian.net>
Thu, 14 Jul 2022 11:17:37 +0000 (13:17 +0200)
committerFabian Grünbichler <debian@fabian.gruenbichler.email>
Tue, 27 Jun 2023 15:12:20 +0000 (16:12 +0100)
===================================================================

Gbp-Pq: Name u-rustc-llvm-cross-flags.patch

compiler/rustc_llvm/build.rs

index 0c95da585b7a6ae64363491f033382191d053c3d..9804afb51c39c2653c938e92bc2537a22f233e22 100644 (file)
@@ -301,7 +301,7 @@ fn main() {
             if let Some(stripped) = lib.strip_prefix("-LIBPATH:") {
                 println!("cargo:rustc-link-search=native={}", stripped.replace(&host, &target));
             } else if let Some(stripped) = lib.strip_prefix("-L") {
-                println!("cargo:rustc-link-search=native={}", stripped.replace(&host, &target));
+                if stripped.contains(&host) { println!("cargo:rustc-link-search=native={}", stripped.replace(&host, &target)); }
             }
         } else if let Some(stripped) = lib.strip_prefix("-LIBPATH:") {
             println!("cargo:rustc-link-search=native={}", stripped);