Skip to content

Commit c070d30

Browse files
committed
Add LLVM based mingw-w64 targets
1 parent 2a768f1 commit c070d30

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

unwind/build.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ fn main() {
3636
println!("cargo:rustc-link-lib=gcc_s");
3737
} else if target.contains("dragonfly") {
3838
println!("cargo:rustc-link-lib=gcc_pic");
39-
} else if target.contains("pc-windows-gnu") {
39+
} else if target.ends_with("pc-windows-gnu") {
4040
// This is handled in the target spec with late_link_args_[static|dynamic]
4141
} else if target.contains("uwp-windows-gnu") {
4242
println!("cargo:rustc-link-lib=unwind");

unwind/src/lib.rs

+5
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
#![feature(nll)]
66
#![feature(staged_api)]
77
#![feature(c_unwind)]
8+
#![feature(cfg_target_abi)]
89
#![cfg_attr(not(target_env = "msvc"), feature(libc))]
910

1011
cfg_if::cfg_if! {
@@ -85,3 +86,7 @@ extern "C" {}
8586
#[cfg(all(target_vendor = "fortanix", target_env = "sgx"))]
8687
#[link(name = "unwind", kind = "static", modifiers = "-bundle")]
8788
extern "C" {}
89+
90+
#[cfg(all(target_os = "windows", target_env = "gnu", target_abi = "llvm"))]
91+
#[link(name = "unwind", kind = "static", modifiers = "-bundle")]
92+
extern "C" {}

0 commit comments

Comments
 (0)