u-rustc-llvm-cross-flags
authorDebian Rust Maintainers <pkg-rust-maintainers@alioth-lists.debian.net>
Tue, 8 Sep 2020 16:38:19 +0000 (17:38 +0100)
committerEmilio Pozuelo Monfort <pochu@debian.org>
Tue, 8 Sep 2020 16:38:19 +0000 (17:38 +0100)
Gbp-Pq: Name u-rustc-llvm-cross-flags.patch

src/librustc_llvm/build.rs

index c15b3ba2368a80d76f0ea42d5d63409201fae55c..fe996531610cd109f79affb0c75d1b68dbf1cde7 100644 (file)
@@ -229,7 +229,7 @@ fn main() {
         if lib.starts_with("-LIBPATH:") {
             println!("cargo:rustc-link-search=native={}", &lib[9..]);
         } else if is_crossed {
-            if lib.starts_with("-L") {
+            if lib.starts_with("-L") && lib[2..].contains(&host) {
                 println!("cargo:rustc-link-search=native={}",
                          lib[2..].replace(&host, &target));
             }