Skip to content

Commit

Permalink
Fix Miri sysroot for x run
Browse files Browse the repository at this point in the history
Miri no longer respects `MIRI_SYSROOT` and wants to be treated like a
REAL rustc, with `--sysroot`. *pats Miri* sure Miri, just for you :3.
  • Loading branch information
Noratrieb committed Jun 10, 2024
1 parent a316785 commit 5f75375
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/bootstrap/src/core/build_steps/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -149,12 +149,13 @@ 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);
miri.arg("--").arg("--target").arg(target.rustc_target_arg());

// Forward arguments.
miri.args(builder.config.args());

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

0 comments on commit 5f75375

Please sign in to comment.