Skip to content

Commit

Permalink
Unrolled build for rust-lang#127677
Browse files Browse the repository at this point in the history
Rollup merge of rust-lang#127677 - onur-ozkan:use-correct-modes, r=Kobzol

using correct tool mode for `run-make-support` crate

We don't need to ensure std (and rustc) for testing run-make-support's unit tests. Using stage 0 compiler is already enough and speeds up `x test run-make-support` invocations on a clean build.
  • Loading branch information
rust-timer authored Jul 14, 2024
2 parents 00167ab + 41070bd commit 671452d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/bootstrap/src/core/build_steps/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -682,6 +682,8 @@ impl Step for CompiletestTest {
let mut cargo = tool::prepare_tool_cargo(
builder,
compiler,
// compiletest uses libtest internals; make it use the in-tree std to make sure it never breaks
// when std sources change.
Mode::ToolStd,
host,
"test",
Expand Down Expand Up @@ -1321,13 +1323,12 @@ impl Step for CrateRunMakeSupport {
/// Runs `cargo test` for run-make-support.
fn run(self, builder: &Builder<'_>) {
let host = self.host;
let compiler = builder.compiler(builder.top_stage, host);
let compiler = builder.compiler(0, host);

builder.ensure(compile::Std::new(compiler, host));
let mut cargo = tool::prepare_tool_cargo(
builder,
compiler,
Mode::ToolStd,
Mode::ToolBootstrap,
host,
"test",
"src/tools/run-make-support",
Expand Down

0 comments on commit 671452d

Please sign in to comment.