Skip to content

Commit dc0c76f

Browse files
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.
2 parents c0235de + 41070bd commit dc0c76f

File tree

1 file changed

+4
-3
lines changed
  • src/bootstrap/src/core/build_steps

1 file changed

+4
-3
lines changed

src/bootstrap/src/core/build_steps/test.rs

+4-3
Original file line numberDiff line numberDiff line change
@@ -682,6 +682,8 @@ impl Step for CompiletestTest {
682682
let mut cargo = tool::prepare_tool_cargo(
683683
builder,
684684
compiler,
685+
// compiletest uses libtest internals; make it use the in-tree std to make sure it never breaks
686+
// when std sources change.
685687
Mode::ToolStd,
686688
host,
687689
"test",
@@ -1321,13 +1323,12 @@ impl Step for CrateRunMakeSupport {
13211323
/// Runs `cargo test` for run-make-support.
13221324
fn run(self, builder: &Builder<'_>) {
13231325
let host = self.host;
1324-
let compiler = builder.compiler(builder.top_stage, host);
1326+
let compiler = builder.compiler(0, host);
13251327

1326-
builder.ensure(compile::Std::new(compiler, host));
13271328
let mut cargo = tool::prepare_tool_cargo(
13281329
builder,
13291330
compiler,
1330-
Mode::ToolStd,
1331+
Mode::ToolBootstrap,
13311332
host,
13321333
"test",
13331334
"src/tools/run-make-support",

0 commit comments

Comments
 (0)