blob: 95a5c6230a2486a7464d0887d14e4a1b109bbae6 (
plain) (
tree)
|
|
From 62bea02c5e1ea40f1bd5adc52d4f4f3bd9cb8d95 Mon Sep 17 00:00:00 2001
From: Samuel Holland <samuel@sholland.org>
Date: Sat, 2 Dec 2017 17:25:44 -0600
Subject: [PATCH 03/13] Fix rustdoc when cross-compiling on musl
musl can't handle foreign-architecture libraries in LD_LIBRARY_PATH.
---
src/bootstrap/bin/rustdoc.rs | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/src/bootstrap/bin/rustdoc.rs b/src/bootstrap/bin/rustdoc.rs
index 4ecb3349816ee..496a04670769f 100644
--- a/src/bootstrap/bin/rustdoc.rs
+++ b/src/bootstrap/bin/rustdoc.rs
@@ -32,9 +32,6 @@ fn main() {
Err(_) => 0,
};
- let mut dylib_path = dylib_path();
- dylib_path.insert(0, PathBuf::from(libdir.clone()));
-
let mut cmd = Command::new(rustdoc);
if target.is_some() {
@@ -47,7 +44,7 @@ fn main() {
}
cmd.args(&args);
- cmd.env(dylib_path_var(), env::join_paths(&dylib_path).unwrap());
+ cmd.env(dylib_path_var(), PathBuf::from(libdir.clone()));
// Force all crates compiled by this compiler to (a) be unstable and (b)
// allow the `rustc_private` feature to link to other unstable crates
@@ -79,7 +76,7 @@ fn main() {
eprintln!(
"rustdoc command: {:?}={:?} {:?}",
dylib_path_var(),
- env::join_paths(&dylib_path).unwrap(),
+ PathBuf::from(libdir.clone()),
cmd,
);
eprintln!("sysroot: {sysroot:?}");
|