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 Gruenbichler <debian@fabian.gruenbichler.email>
Mon, 10 Oct 2022 18:19:05 +0000 (19:19 +0100)
===================================================================

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

compiler/rustc_llvm/build.rs

index 0d25d6a86ac3721c87e6e691156395dff40aec25..276d9dcdab8a889cfe1d0d9c601bd3d0043db35b 100644 (file)
@@ -298,7 +298,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);