diff --git a/.cargo/config.toml b/.cargo/config.toml index 91a0e7d076..058bdb84e9 100644 --- a/.cargo/config.toml +++ b/.cargo/config.toml @@ -89,6 +89,9 @@ rustflags = [ "-Ctarget-feature=+crt-static", # Use RELR relocation format, which is considerably smaller. "-Clink-arg=-Wl,-z,pack-relative-relocs", + # Disable unwind tables to reduce binary size. + # TODO: It would be nice to have this enabled for debug builds + "-Cforce-unwind-tables=no", ] [target.'cfg(all(target_arch = "aarch64", target_env = "musl"))'] diff --git a/vm/whp/src/abi.rs b/vm/whp/src/abi.rs index 4c1be17da6..12028aad3a 100644 --- a/vm/whp/src/abi.rs +++ b/vm/whp/src/abi.rs @@ -36,6 +36,7 @@ macro_rules! bitops_base { }; } +#[cfg(target_arch = "x86_64")] pub(crate) use bitops_base; macro_rules! bitops { @@ -69,6 +70,7 @@ macro_rules! bitops { }; } +#[cfg(target_arch = "x86_64")] pub(crate) use bitops; #[repr(C)]