Skip to content

Commit

Permalink
Unrolled build for rust-lang#123189
Browse files Browse the repository at this point in the history
Rollup merge of rust-lang#123189 - Kobzol:rustc-shim-log, r=onur-ozkan

Log BOLT args in bootstrap `rustc` shim

Before, the BOLT argument would not be logged, because it was only added after the logging has happened.

Found by `@RalfJung` [here](rust-lang#116352 (comment)).
  • Loading branch information
rust-timer authored Mar 31, 2024
2 parents 688c30d + a4087b7 commit e779ebe
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/bootstrap/src/bin/rustc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,12 @@ fn main() {
}
}

if env::var_os("RUSTC_BOLT_LINK_FLAGS").is_some() {
if let Some("rustc_driver") = crate_name {
cmd.arg("-Clink-args=-Wl,-q");
}
}

let is_test = args.iter().any(|a| a == "--test");
if verbose > 2 {
let rust_env_vars =
Expand All @@ -244,12 +250,6 @@ fn main() {
eprintln!("{prefix} libdir: {libdir:?}");
}

if env::var_os("RUSTC_BOLT_LINK_FLAGS").is_some() {
if let Some("rustc_driver") = crate_name {
cmd.arg("-Clink-args=-Wl,-q");
}
}

bin_helpers::maybe_dump(format!("stage{stage}-rustc"), &cmd);

let start = Instant::now();
Expand Down

0 comments on commit e779ebe

Please sign in to comment.