diff options
Diffstat (limited to 'library/backtrace/crates')
-rw-r--r-- | library/backtrace/crates/as-if-std/Cargo.toml | 16 | ||||
-rw-r--r-- | library/backtrace/crates/as-if-std/build.rs | 8 |
2 files changed, 19 insertions, 5 deletions
diff --git a/library/backtrace/crates/as-if-std/Cargo.toml b/library/backtrace/crates/as-if-std/Cargo.toml index 012e60f8f..bcbcfe159 100644 --- a/library/backtrace/crates/as-if-std/Cargo.toml +++ b/library/backtrace/crates/as-if-std/Cargo.toml @@ -15,15 +15,21 @@ bench = false cfg-if = "1.0" rustc-demangle = "0.1.21" libc = { version = "0.2.146", default-features = false } -addr2line = { version = "0.20.0", default-features = false, optional = true } -miniz_oxide = { version = "0.7", default-features = false } -[dependencies.object] -version = "0.31.1" +[target.'cfg(not(all(windows, target_env = "msvc", not(target_vendor = "uwp"))))'.dependencies] +miniz_oxide = { version = "0.7.0", optional = true, default-features = false } +addr2line = { version = "0.21.0", optional = true, default-features = false } + +[target.'cfg(not(all(windows, target_env = "msvc", not(target_vendor = "uwp"))))'.dependencies.object] +version = "0.32.0" default-features = false optional = true features = ['read_core', 'elf', 'macho', 'pe', 'unaligned', 'archive'] +[build-dependencies] +# Dependency of the `backtrace` crate +cc = "1.0.67" + [features] default = ['backtrace'] -backtrace = ['addr2line', 'object'] +backtrace = ['addr2line', 'miniz_oxide', 'object'] diff --git a/library/backtrace/crates/as-if-std/build.rs b/library/backtrace/crates/as-if-std/build.rs index 7018b1017..7669f555d 100644 --- a/library/backtrace/crates/as-if-std/build.rs +++ b/library/backtrace/crates/as-if-std/build.rs @@ -1,3 +1,11 @@ +// backtrace-rs requires a feature check on Android targets, so +// we need to run its build.rs as well. +#[allow(unused_extern_crates)] +#[path = "../../build.rs"] +mod backtrace_build_rs; + fn main() { println!("cargo:rustc-cfg=backtrace_in_libstd"); + + backtrace_build_rs::main(); } |