Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

skip in-tree compiler build for llvm-bitcode-linker if ci-rustc is on #130479

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions src/bootstrap/src/core/build_steps/tool.rs
Original file line number Diff line number Diff line change
Expand Up @@ -872,8 +872,11 @@ impl Step for LlvmBitcodeLinker {
fn run(self, builder: &Builder<'_>) -> PathBuf {
let bin_name = "llvm-bitcode-linker";

builder.ensure(compile::Std::new(self.compiler, self.compiler.host));
builder.ensure(compile::Rustc::new(self.compiler, self.target));
// If enabled, use ci-rustc and skip building the in-tree compiler.
if !builder.download_rustc() {
builder.ensure(compile::Std::new(self.compiler, self.compiler.host));
Comment on lines +876 to +877
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could be resolved within the impl Step for Std logic, but I couldn't find a simple and clean solution without requiring a refactor. I wanted to unblock the #122709 PR in the simplest way possible without introducing complex changes to the std bootstrapping logic.

builder.ensure(compile::Rustc::new(self.compiler, self.target));
}

let cargo = prepare_tool_cargo(
builder,
Expand Down
Loading