Skip to content

Commit d778203

Browse files
committed
Auto merge of #76573 - Mark-Simulacrum:bootstrap-with-external-llvm, r=alexcrichton
Only copy LLVM into rust-dev with internal LLVM This avoids needing to figure out where to locate each of the components with an external LLVM. This component isn't manifested for rustup consumption and generally shouldn't matter for anyone except Rust's CI, so it is fine for it to not be complete elsewhere. Fixes #76572. r? `@alexcrichton`
2 parents a742547 + 4f2d941 commit d778203

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/bootstrap/dist.rs

+9
Original file line numberDiff line numberDiff line change
@@ -2524,6 +2524,14 @@ impl Step for RustDev {
25242524
fn run(self, builder: &Builder<'_>) -> Option<PathBuf> {
25252525
let target = self.target;
25262526

2527+
/* run only if llvm-config isn't used */
2528+
if let Some(config) = builder.config.target_config.get(&target) {
2529+
if let Some(ref _s) = config.llvm_config {
2530+
builder.info(&format!("Skipping RustDev ({}): external LLVM", target));
2531+
return None;
2532+
}
2533+
}
2534+
25272535
builder.info(&format!("Dist RustDev ({})", target));
25282536
let _time = timeit(builder);
25292537
let src = builder.src.join("src/llvm-project/llvm");
@@ -2536,6 +2544,7 @@ impl Step for RustDev {
25362544
// Prepare the image directory
25372545
let dst_bindir = image.join("bin");
25382546
t!(fs::create_dir_all(&dst_bindir));
2547+
25392548
let exe = builder.llvm_out(target).join("bin").join(exe("llvm-config", target));
25402549
builder.install(&exe, &dst_bindir, 0o755);
25412550
builder.install(&builder.llvm_filecheck(target), &dst_bindir, 0o755);

0 commit comments

Comments
 (0)