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)
committerPeter Michael Green <plugwash@raspbian.org>
Thu, 13 Jun 2024 11:01:11 +0000 (11:01 +0000)
===================================================================

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

compiler/rustc_llvm/build.rs

index c8c60e5781b85c3574ae466a370df3d1c092c27f..b46682b73fd1c1e37cfd67d5826b123086d9c11a 100644 (file)
@@ -305,7 +305,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}");