Fix building compiler docs with stage 0

This commit is contained in:
Joshua Nelson
2020-12-11 20:27:28 -05:00
parent 39b841dfe3
commit 9df0348299
2 changed files with 8 additions and 2 deletions
+4 -1
View File
@@ -732,11 +732,14 @@ pub fn rustdoc_cmd(&self, compiler: Compiler) -> Command {
.env("CFG_RELEASE_CHANNEL", &self.config.channel)
.env("RUSTDOC_REAL", self.rustdoc(compiler))
.env("RUSTC_BOOTSTRAP", "1")
.arg("-Znormalize_docs")
.arg("-Winvalid_codeblock_attributes");
if self.config.deny_warnings {
cmd.arg("-Dwarnings");
}
// cfg(not(bootstrap)), can be removed on the next beta bump
if compiler.stage != 0 {
cmd.arg("-Znormalize-docs");
}
// Remove make-related flags that can cause jobserver problems.
cmd.env_remove("MAKEFLAGS");
+4 -1
View File
@@ -527,7 +527,10 @@ fn run(self, builder: &Builder<'_>) {
cargo.rustdocflag("--document-private-items");
cargo.rustdocflag("--enable-index-page");
cargo.rustdocflag("-Zunstable-options");
cargo.rustdocflag("-Znormalize-docs");
// cfg(not(bootstrap)), can be removed on the next beta bump
if stage != 0 {
cargo.rustdocflag("-Znormalize-docs");
}
compile::rustc_cargo(builder, &mut cargo, target);
// Only include compiler crates, no dependencies of those, such as `libc`.