Skip to content

Commit

Permalink
Unrolled build for rust-lang#126238
Browse files Browse the repository at this point in the history
Rollup merge of rust-lang#126238 - Nilstrieb:run,miri,run, r=RalfJung

Fix Miri sysroot for `x run`

Miri no longer (after rust-lang/miri#3411) respects `MIRI_SYSROOT` and wants to be treated like a REAL rustc, with `--sysroot`. \*pats Miri\* sure Miri, just for you :3.

fixes rust-lang#126233

r? RalfJung (or whoever else feels like it)
  • Loading branch information
rust-timer authored Jun 14, 2024
2 parents 0ef0dd2 + a1667a9 commit f7c804f
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/bootstrap/src/core/build_steps/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -149,12 +149,14 @@ impl Step for Miri {
&[],
);
miri.add_rustc_lib_path(builder);
// Forward arguments.
miri.arg("--").arg("--target").arg(target.rustc_target_arg());
miri.args(builder.config.args());

// miri tests need to know about the stage sysroot
miri.env("MIRI_SYSROOT", &miri_sysroot);
miri.arg("--sysroot").arg(miri_sysroot);

// Forward arguments. This may contain further arguments to the program
// after another --, so this must be at the end.
miri.args(builder.config.args());

let mut miri = Command::from(miri);
builder.run(&mut miri);
Expand Down

0 comments on commit f7c804f

Please sign in to comment.