From 71d35d8d0c143eed482382b19d35103743c015ae Mon Sep 17 00:00:00 2001 From: r0cky Date: Thu, 7 Mar 2024 17:38:13 +0800 Subject: [PATCH] remove the --generate-link-to-definition flags from bootstrap --- src/bootstrap/src/core/build_steps/doc.rs | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/bootstrap/src/core/build_steps/doc.rs b/src/bootstrap/src/core/build_steps/doc.rs index a4903ce235365..c4235755ba865 100644 --- a/src/bootstrap/src/core/build_steps/doc.rs +++ b/src/bootstrap/src/core/build_steps/doc.rs @@ -797,7 +797,10 @@ impl Step for Rustc { cargo.rustdocflag("-Zunstable-options"); cargo.rustdocflag("-Znormalize-docs"); cargo.rustdocflag("--show-type-layout"); - cargo.rustdocflag("--generate-link-to-definition"); + // FIXME: `--generate-link-to-definition` tries to resolve cfged out code + // see https://github.com/rust-lang/rust/pull/122066#issuecomment-1983049222 + // cargo.rustdocflag("--generate-link-to-definition"); + compile::rustc_cargo(builder, &mut cargo, target, compiler.stage); cargo.arg("-Zunstable-options"); cargo.arg("-Zskip-rustdoc-fingerprint"); @@ -953,8 +956,10 @@ macro_rules! tool_doc { cargo.rustdocflag("-Arustdoc::private-intra-doc-links"); cargo.rustdocflag("--enable-index-page"); cargo.rustdocflag("--show-type-layout"); - cargo.rustdocflag("--generate-link-to-definition"); cargo.rustdocflag("-Zunstable-options"); + // FIXME: `--generate-link-to-definition` tries to resolve cfged out code + // see https://github.com/rust-lang/rust/pull/122066#issuecomment-1983049222 + // cargo.rustdocflag("--generate-link-to-definition"); let out_dir = builder.stage_out(compiler, Mode::ToolRustc).join(target.triple).join("doc"); $(for krate in $crates {