Skip to content

Commit

Permalink
Assemble libLLVM into the target lib-dir too
Browse files Browse the repository at this point in the history
  • Loading branch information
cuviper committed May 13, 2020
1 parent 86c29d6 commit 90b2c8e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/bootstrap/compile.rs
Original file line number Diff line number Diff line change
Expand Up @@ -773,6 +773,7 @@ impl Step for Assemble {
// Ensure that `libLLVM.so` ends up in the newly build compiler directory,
// so that it can be found when the newly built `rustc` is run.
dist::maybe_install_llvm_runtime(builder, target_compiler.host, &sysroot);
dist::maybe_install_llvm_target(builder, target_compiler.host, &sysroot);

// Link the compiler binary itself into place
let out_dir = builder.cargo_out(build_compiler, Mode::Rustc, host);
Expand Down
2 changes: 1 addition & 1 deletion src/bootstrap/dist.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2267,7 +2267,7 @@ fn maybe_install_llvm(builder: &Builder<'_>, target: Interned<String>, dst_libdi
}

/// Maybe add libLLVM.so to the target lib-dir for linking.
fn maybe_install_llvm_target(builder: &Builder<'_>, target: Interned<String>, sysroot: &Path) {
pub fn maybe_install_llvm_target(builder: &Builder<'_>, target: Interned<String>, sysroot: &Path) {
let dst_libdir = sysroot.join("lib/rustlib").join(&*target).join("lib");
maybe_install_llvm(builder, target, &dst_libdir);
}
Expand Down

0 comments on commit 90b2c8e

Please sign in to comment.