Skip to content

Commit

Permalink
Print out the sysroot and libdir on verbose builds.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mark-Simulacrum committed Mar 9, 2018
1 parent 1c8f3b0 commit c8edb36
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/bootstrap/bin/rustc.rs
Expand Up @@ -95,7 +95,7 @@ fn main() {
let rustc = env::var_os(rustc).unwrap_or_else(|| panic!("{:?} was not set", rustc));
let libdir = env::var_os(libdir).unwrap_or_else(|| panic!("{:?} was not set", libdir));
let mut dylib_path = bootstrap::util::dylib_path();
dylib_path.insert(0, PathBuf::from(libdir));
dylib_path.insert(0, PathBuf::from(&libdir));

let mut cmd = Command::new(rustc);
cmd.args(&args)
Expand All @@ -107,7 +107,7 @@ fn main() {
if let Some(target) = target {
// The stage0 compiler has a special sysroot distinct from what we
// actually downloaded, so we just always pass the `--sysroot` option.
cmd.arg("--sysroot").arg(sysroot);
cmd.arg("--sysroot").arg(&sysroot);

// When we build Rust dylibs they're all intended for intermediate
// usage, so make sure we pass the -Cprefer-dynamic flag instead of
Expand Down Expand Up @@ -280,6 +280,8 @@ fn main() {

if verbose > 1 {
eprintln!("rustc command: {:?}", cmd);
eprintln!("sysroot: {:?}", sysroot);
eprintln!("libdir: {:?}", libdir);
}

// Actually run the compiler!
Expand Down

0 comments on commit c8edb36

Please sign in to comment.