[package]
name = "crash_helper_server"
version = "0.1.0"
authors = ["Gabriele Svelto <gsvelto@mozilla.com>"]
edition = "2021"

[dependencies]
anyhow = "1"
cfg-if = "1"
crash_helper_common = { path = "../crash_helper_common" }
dirs = "4"
log = "0.4"
mozannotation_server = { path = "../mozannotation_server" }
mozbuild = "0.1"
mozilla-central-workspace-hack = { version = "0.1", features = [
    "crash_helper_server",
], optional = true }
num-traits = "0.2"
once_cell = "1"
thiserror = "2"
uuid = { version = "1.0", features = ["v4"] }

# Use android_logger on Android, env_logger everywhere else
[target.'cfg(not(target_os = "android"))'.dependencies]
env_logger = { version = "0.10", default-features = false }
[target.'cfg(target_os = "android")'.dependencies]
android_logger = "0.12"

[target."cfg(any(target_os = \"android\", target_os = \"linux\"))".dependencies]
nix = { version = "0.30", features = ["process", "poll", "socket", "uio"] }
minidump-writer = { git = "https://github.com/rust-minidump/minidump-writer.git", rev = "45f5459790d264098346343f0ad58d008c386fa5" }
rust_minidump_writer_linux = { path = "../rust_minidump_writer_linux" }

[target."cfg(target_os = \"windows\")".dependencies]
windows-sys = { version = "0.61", features = [
    "Win32_Foundation",
    "Win32_Storage_FileSystem",
    "Win32_System_Kernel",
    "Win32_System_Memory",
    "Win32_System_SystemInformation",
    "Win32_System_SystemServices",
] }

[target."cfg(target_os = \"macos\")".dependencies]
nix = { version = "0.30", features = ["process", "fs", "poll", "socket", "uio"] }

[build-dependencies]
cc = "1"

[lib]
name = "crash_helper_server"
crate-type = ["staticlib"]
path = "src/lib.rs"
