Skip to content

Commit 654288b

Browse files
committed
Remove obsolete support for linking unwinder on Android
Linking libgcc is no longer supported (see #103673), so remove the related link attributes and the check in unwind's build.rs. The check was the last remaining significant piece of logic in build.rs, so remove build.rs as well.
1 parent 722b3ee commit 654288b

File tree

4 files changed

+1
-34
lines changed

4 files changed

+1
-34
lines changed

Cargo.lock

-1
Original file line numberDiff line numberDiff line change
@@ -5929,7 +5929,6 @@ dependencies = [
59295929
name = "unwind"
59305930
version = "0.0.0"
59315931
dependencies = [
5932-
"cc",
59335932
"cfg-if",
59345933
"compiler_builtins",
59355934
"core",

library/unwind/Cargo.toml

-3
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,6 @@ libc = { version = "0.2.79", features = ['rustc-dep-of-std'], default-features =
1919
compiler_builtins = "0.1.0"
2020
cfg-if = "1.0"
2121

22-
[build-dependencies]
23-
cc = "1.0.76"
24-
2522
[features]
2623

2724
# Only applies for Linux and Fuchsia targets

library/unwind/build.rs

-25
This file was deleted.

library/unwind/src/lib.rs

+1-5
Original file line numberDiff line numberDiff line change
@@ -76,14 +76,10 @@ cfg_if::cfg_if! {
7676
cfg_if::cfg_if! {
7777
if #[cfg(feature = "llvm-libunwind")] {
7878
compile_error!("`llvm-libunwind` is not supported for Android targets");
79-
} else if #[cfg(feature = "system-llvm-libunwind")] {
79+
} else {
8080
#[link(name = "unwind", kind = "static", modifiers = "-bundle", cfg(target_feature = "crt-static"))]
8181
#[link(name = "unwind", cfg(not(target_feature = "crt-static")))]
8282
extern "C" {}
83-
} else {
84-
#[link(name = "gcc", kind = "static", modifiers = "-bundle", cfg(target_feature = "crt-static"))]
85-
#[link(name = "gcc", cfg(not(target_feature = "crt-static")))]
86-
extern "C" {}
8783
}
8884
}
8985
// Android's unwinding library depends on dl_iterate_phdr in `libdl`.

0 commit comments

Comments
 (0)