1include!(concat!(env!("OUT_DIR"), "/bindings.rs"));
2
3#[cfg(not(target_os = "windows"))]
4const DEFAULT_HANDLER_NAME: &str = "crashpad_handler";
5#[cfg(target_os = "windows")]
6const DEFAULT_HANDLER_NAME: &str = "crashpad_handler.exe";
7
8#[cfg(all(feature = "with-precompiled", not(target_os = "windows")))]
9const HANDLER: &[u8] = include_bytes!(concat!(env!("OUT_DIR"), "/bin/crashpad_handler"));
10#[cfg(all(feature = "with-precompiled", target_os = "windows"))]
11const HANDLER: &[u8] = include_bytes!(concat!(env!("OUT_DIR"), "/bin/crashpad_handler.exe"));
12
13pub const fn handler_name() -> &'static str {
15 DEFAULT_HANDLER_NAME
16}
17
18#[cfg(not(feature = "with-precompiled"))]
22pub const fn precompiled_handler() -> Option<&'static [u8]> {
23 None
24}
25#[cfg(feature = "with-precompiled")]
26pub const fn precompiled_handler() -> Option<&'static [u8]> {
27 Some(HANDLER)
28}