unwind: Move linux-gnu library linking to lib.rs and libc

This unifies it with the handling of `target-feature=+crt-static` on
other platforms, and allows for supporting static glibc in the future.
This commit is contained in:
Josh Triplett
2020-09-20 21:19:34 -07:00
parent 16ebf750cf
commit 9d952cbe95
2 changed files with 5 additions and 3 deletions

View File

@@ -42,6 +42,10 @@ cfg_if::cfg_if! {
#[link(name = "gcc_s", cfg(not(target_feature = "crt-static")))]
extern "C" {}
#[cfg(all(target_os = "linux", target_env = "gnu", not(feature = "llvm-libunwind")))]
#[link(name = "gcc_s", cfg(not(target_feature = "crt-static")))]
extern "C" {}
#[cfg(target_os = "redox")]
#[link(name = "gcc_eh", kind = "static-nobundle", cfg(target_feature = "crt-static"))]
#[link(name = "gcc_s", cfg(not(target_feature = "crt-static")))]