Prefer helper functions to identify MinGW targets
This commit is contained in:
parent
dfe1b8c97b
commit
dc61415746
2 changed files with 3 additions and 4 deletions
|
|
@ -347,14 +347,14 @@ fn runtime_dll_dist(rust_root: &Path, target: TargetSelection, builder: &Builder
|
|||
|
||||
let mut rustc_dlls = vec![];
|
||||
// windows-gnu and windows-gnullvm require different runtime libs
|
||||
if target.ends_with("windows-gnu") {
|
||||
if target.is_windows_gnu() {
|
||||
rustc_dlls.push("libwinpthread-1.dll");
|
||||
if target.starts_with("i686-") {
|
||||
rustc_dlls.push("libgcc_s_dw2-1.dll");
|
||||
} else {
|
||||
rustc_dlls.push("libgcc_s_seh-1.dll");
|
||||
}
|
||||
} else if target.ends_with("windows-gnullvm") {
|
||||
} else if target.is_windows_gnullvm() {
|
||||
rustc_dlls.push("libunwind.dll");
|
||||
} else {
|
||||
panic!("Vendoring of runtime DLLs for `{target}` is not supported`");
|
||||
|
|
|
|||
|
|
@ -284,8 +284,7 @@ impl Step for Llvm {
|
|||
LlvmBuildStatus::ShouldBuild(m) => m,
|
||||
};
|
||||
|
||||
if builder.llvm_link_shared() && target.is_windows() && !target.ends_with("windows-gnullvm")
|
||||
{
|
||||
if builder.llvm_link_shared() && target.is_windows() && !target.is_windows_gnullvm() {
|
||||
panic!("shared linking to LLVM is not currently supported on {}", target.triple);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue