rustbuild: Fix MSBuild location of llvm-config.exe
For LLD integration the path to `llvm-config` needed to change to inside the build directory itself (for whatever reason) but the build directory is different on MSBuild than it is on `ninja` for MSVC builds, so the path to `llvm-config.exe` was actually wrong and not working! This commit removes the `Build::llvm_config` function in favor of the source of truth, the `Llvm` build step itself. The build step was then updated to find the right build directory for MSBuild as well as `ninja` for where `llvm-config.exe` is located. Closes #48749
This commit is contained in:
parent
fedce67cd2
commit
be902e7168
6 changed files with 20 additions and 24 deletions
|
|
@ -81,11 +81,14 @@ impl Step for Llvm {
|
|||
|
||||
let (out_dir, llvm_config_ret_dir) = if emscripten {
|
||||
let dir = build.emscripten_llvm_out(target);
|
||||
let config_dir = dir.join("build/bin");
|
||||
let config_dir = dir.join("bin");
|
||||
(dir, config_dir)
|
||||
} else {
|
||||
(build.llvm_out(target),
|
||||
build.llvm_out(build.config.build).join("build/bin"))
|
||||
let mut dir = build.llvm_out(build.config.build);
|
||||
if !build.config.build.contains("msvc") || build.config.ninja {
|
||||
dir.push("build");
|
||||
}
|
||||
(build.llvm_out(target), dir.join("bin"))
|
||||
};
|
||||
let done_stamp = out_dir.join("llvm-finished-building");
|
||||
let build_llvm_config = llvm_config_ret_dir
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue