diff options
| author | bors <bors@rust-lang.org> | 2020-06-01 19:03:23 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2020-06-01 19:03:23 +0000 |
| commit | ad4bc3323b9299d867697e9653dcea1b5e1ad283 (patch) | |
| tree | f768128570517b6bc243869a84b66ca257dca473 /src | |
| parent | d3cba254e464303a6495942f3a831c2bbd7f1768 (diff) | |
| parent | 759e495bbf33dd510deb7aa645622f8f4388b406 (diff) | |
| download | rust-ad4bc3323b9299d867697e9653dcea1b5e1ad283.tar.gz rust-ad4bc3323b9299d867697e9653dcea1b5e1ad283.zip | |
Auto merge of #72779 - RalfJung:miri, r=oli-obk
bump Miri, update for cargo-miri being a separate project r? @oli-obk Fixes https://github.com/rust-lang/rust/issues/72801
Diffstat (limited to 'src')
| -rw-r--r-- | src/bootstrap/builder.rs | 2 | ||||
| -rw-r--r-- | src/bootstrap/test.rs | 15 | ||||
| -rw-r--r-- | src/bootstrap/tool.rs | 4 | ||||
| m--------- | src/tools/miri | 18 |
4 files changed, 25 insertions, 14 deletions
diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs index c8a85eae252..ffdd8485181 100644 --- a/src/bootstrap/builder.rs +++ b/src/bootstrap/builder.rs @@ -344,10 +344,12 @@ impl<'a> Builder<'a> { tool::Rls, tool::Rustdoc, tool::Clippy, + tool::CargoClippy, native::Llvm, native::Sanitizers, tool::Rustfmt, tool::Miri, + tool::CargoMiri, native::Lld ), Kind::Check | Kind::Clippy | Kind::Fix | Kind::Format => { diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs index f1305e2540b..9f305ea4729 100644 --- a/src/bootstrap/test.rs +++ b/src/bootstrap/test.rs @@ -360,7 +360,12 @@ impl Step for Miri { let miri = builder.ensure(tool::Miri { compiler, target: self.host, extra_features: Vec::new() }); - if let Some(miri) = miri { + let cargo_miri = builder.ensure(tool::CargoMiri { + compiler, + target: self.host, + extra_features: Vec::new(), + }); + if let (Some(miri), Some(_cargo_miri)) = (miri, cargo_miri) { let mut cargo = builder.cargo(compiler, Mode::ToolRustc, host, "install"); cargo.arg("xargo"); // Configure `cargo install` path. cargo adds a `bin/`. @@ -378,14 +383,16 @@ impl Step for Miri { Mode::ToolRustc, host, "run", - "src/tools/miri", + "src/tools/miri/cargo-miri", SourceType::Submodule, &[], ); - cargo.arg("--bin").arg("cargo-miri").arg("--").arg("miri").arg("setup"); + cargo.arg("--").arg("miri").arg("setup"); // Tell `cargo miri setup` where to find the sources. cargo.env("XARGO_RUST_SRC", builder.src.join("src")); + // Tell it where to find Miri. + cargo.env("MIRI", &miri); // Debug things. cargo.env("RUST_BACKTRACE", "1"); // Overwrite bootstrap's `rustc` wrapper overwriting our flags. @@ -437,7 +444,7 @@ impl Step for Miri { // miri tests need to know about the stage sysroot cargo.env("MIRI_SYSROOT", miri_sysroot); cargo.env("RUSTC_LIB_PATH", builder.rustc_libdir(compiler)); - cargo.env("MIRI_PATH", miri); + cargo.env("MIRI", miri); cargo.arg("--").args(builder.config.cmd.test_args()); diff --git a/src/bootstrap/tool.rs b/src/bootstrap/tool.rs index 5f58f00a2a2..6cd9f9029c9 100644 --- a/src/bootstrap/tool.rs +++ b/src/bootstrap/tool.rs @@ -649,12 +649,14 @@ macro_rules! tool_extended { } } +// Note: tools need to be also added to `Builder::get_step_descriptions` in `build.rs` +// to make `./x.py build <tool>` work. tool_extended!((self, builder), Cargofmt, rustfmt, "src/tools/rustfmt", "cargo-fmt", {}; CargoClippy, clippy, "src/tools/clippy", "cargo-clippy", {}; Clippy, clippy, "src/tools/clippy", "clippy-driver", {}; Miri, miri, "src/tools/miri", "miri", {}; - CargoMiri, miri, "src/tools/miri", "cargo-miri", {}; + CargoMiri, miri, "src/tools/miri/cargo-miri", "cargo-miri", {}; Rls, rls, "src/tools/rls", "rls", { builder.ensure(Clippy { compiler: self.compiler, diff --git a/src/tools/miri b/src/tools/miri -Subproject a6c28f08458e15cead0e80f3b5b7009786bce4a +Subproject faff9a7ad9f2d07c1702bd8be392134d27e3eaf |
