mirror of
https://github.com/logos-blockchain/lez-programs.git
synced 2026-08-26 22:51:14 +00:00
18 lines
562 B
Rust
18 lines
562 B
Rust
use std::env;
|
|||
|
|
|
||
|
|
fn main() {
|
||
|
|
let Ok(target_os) = env::var("CARGO_CFG_TARGET_OS") else {
|
||
|
|
return;
|
||
|
|
};
|
||
|
|
|
||
|
|
// RISC Zero's host-side serde dependency contains guest syscall shims with exported C names.
|
||
|
|
// They are implementation details of this cdylib and would otherwise leak beside the three
|
||
|
|
// supported amm_client_* entry points.
|
||
|
|
if matches!(
|
||
|
|
target_os.as_str(),
|
||
|
|
"android" | "dragonfly" | "freebsd" | "linux" | "netbsd" | "openbsd"
|
||
|
|
) {
|
||
|
|
println!("cargo:rustc-cdylib-link-arg=-Wl,--exclude-libs,ALL");
|
||
|
|
}
|
||
|
|
}
|