diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2019-09-09 10:21:15 -0700 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2019-09-23 09:34:44 -0700 |
| commit | 3d13f463045417903364c44a67b0963ececde79f (patch) | |
| tree | 4d9b26497fdd16a7a1b1208cdb784e9d98dd9c6f /src/bootstrap/bin | |
| parent | 0b6766d8d7461a1a8d632ff62ba2024be87fed76 (diff) | |
Move handling of `{MUSL,WASI}_ROOT` to `compile.rs`
No longer any need for them to live in `rustc.rs`!
Diffstat (limited to 'src/bootstrap/bin')
| -rw-r--r-- | src/bootstrap/bin/rustc.rs | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/src/bootstrap/bin/rustc.rs b/src/bootstrap/bin/rustc.rs index df7ed48c186..8c460c59f07 100644 --- a/src/bootstrap/bin/rustc.rs +++ b/src/bootstrap/bin/rustc.rs @@ -16,7 +16,6 @@ //! never get replaced. use std::env; -use std::ffi::OsString; use std::io; use std::path::PathBuf; use std::process::Command; @@ -97,7 +96,7 @@ fn main() { cmd.env("RUST_BACKTRACE", "1"); } - if let Some(target) = target { + if target.is_some() { // The stage0 compiler has a special sysroot distinct from what we // actually downloaded, so we just always pass the `--sysroot` option, // unless one is already set. @@ -112,23 +111,6 @@ fn main() { cmd.arg("-Cprefer-dynamic"); } - // Help the libc crate compile by assisting it in finding various - // sysroot native libraries. - if let Some(s) = env::var_os("MUSL_ROOT") { - if target.contains("musl") { - let mut root = OsString::from("native="); - root.push(&s); - root.push("/lib"); - cmd.arg("-L").arg(&root); - } - } - if let Some(s) = env::var_os("WASI_ROOT") { - let mut root = OsString::from("native="); - root.push(&s); - root.push("/lib/wasm32-wasi"); - cmd.arg("-L").arg(&root); - } - // If we're compiling specifically the `panic_abort` crate then we pass // the `-C panic=abort` option. Note that we do not do this for any // other crate intentionally as this is the only crate for now that we |
