Skip to content

Commit 8318ef2

Browse files
committedOct 26, 2019
Auto merge of #65758 - RalfJung:miri, r=oli-obk
update Miri Fixes #65684
2 parents 084edc4 + 58da335 commit 8318ef2

File tree

2 files changed

+12
-5
lines changed

2 files changed

+12
-5
lines changed
 

‎src/bootstrap/test.rs

+11-4
Original file line numberDiff line numberDiff line change
@@ -386,8 +386,17 @@ impl Step for Miri {
386386
extra_features: Vec::new(),
387387
});
388388
if let Some(miri) = miri {
389+
let mut cargo = builder.cargo(compiler, Mode::ToolRustc, host, "install");
390+
cargo.arg("xargo");
391+
// Configure `cargo install` path. cargo adds a `bin/`.
392+
cargo.env("CARGO_INSTALL_ROOT", &builder.out);
393+
394+
let mut cargo = Command::from(cargo);
395+
if !try_run(builder, &mut cargo) {
396+
return;
397+
}
398+
389399
// # Run `cargo miri setup`.
390-
// As a side-effect, this will install xargo.
391400
let mut cargo = tool::prepare_tool_cargo(
392401
builder,
393402
compiler,
@@ -412,9 +421,7 @@ impl Step for Miri {
412421
cargo.env("XARGO_RUST_SRC", builder.src.join("src"));
413422
// Debug things.
414423
cargo.env("RUST_BACKTRACE", "1");
415-
// Configure `cargo install` path, and let cargo-miri know that that's where
416-
// xargo ends up.
417-
cargo.env("CARGO_INSTALL_ROOT", &builder.out); // cargo adds a `bin/`
424+
// Let cargo-miri know where xargo ended up.
418425
cargo.env("XARGO", builder.out.join("bin").join("xargo"));
419426

420427
let mut cargo = Command::from(cargo);

0 commit comments

Comments
 (0)
Please sign in to comment.