Skip to content

Commit 261da71

Browse files
committed
Ensure CleanTools is run for check rustdoc
1 parent baf940d commit 261da71

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

src/bootstrap/builder.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,8 @@ impl<'a> Builder<'a> {
310310
tool::Compiletest, tool::RemoteTestServer, tool::RemoteTestClient,
311311
tool::RustInstaller, tool::Cargo, tool::Rls, tool::Rustdoc, tool::Clippy,
312312
native::Llvm, tool::Rustfmt, tool::Miri, native::Lld),
313-
Kind::Check => describe!(check::Std, check::Test, check::Rustc, check::CodegenBackend, check::Rustdoc),
313+
Kind::Check => describe!(check::Std, check::Test, check::Rustc, check::CodegenBackend,
314+
check::Rustdoc),
314315
Kind::Test => describe!(test::Tidy, test::Bootstrap, test::Ui, test::RunPass,
315316
test::CompileFail, test::ParseFail, test::RunFail, test::RunPassValgrind,
316317
test::MirOpt, test::Codegen, test::CodegenUnits, test::Incremental, test::Debuginfo,

src/bootstrap/check.rs

+7-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
1313
use compile::{run_cargo, std_cargo, test_cargo, rustc_cargo, rustc_cargo_env, add_to_sysroot};
1414
use builder::{RunConfig, Builder, ShouldRun, Step};
15-
use tool::prepare_tool_cargo;
15+
use tool::{self, prepare_tool_cargo};
1616
use {Compiler, Mode};
1717
use cache::{INTERNER, Interned};
1818
use std::path::PathBuf;
@@ -232,6 +232,12 @@ impl Step for Rustdoc {
232232

233233
let libdir = builder.sysroot_libdir(compiler, target);
234234
add_to_sysroot(&builder, &libdir, &rustdoc_stamp(builder, compiler, target));
235+
236+
builder.ensure(tool::CleanTools {
237+
compiler,
238+
target,
239+
mode: Mode::Tool,
240+
});
235241
}
236242
}
237243

0 commit comments

Comments
 (0)