Skip to content

Commit 734e694

Browse files
Don't force link cabi_realloc on non-Wasm builds.
1 parent e5cbca3 commit 734e694

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • crates/guest-rust/src/rt

crates/guest-rust/src/rt/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ mod wit_bindgen_cabi_realloc;
122122
///
123123
/// For more information about this see `./ci/rebuild-libwit-bindgen-cabi.sh`.
124124
pub fn maybe_link_cabi_realloc() {
125-
#[cfg(any(target_env = "p1", target_env = ""))]
125+
#[cfg(all(target_family = "wasm", any(target_env = "p1", target_env = "")))]
126126
{
127127
unsafe extern "C" {
128128
fn cabi_realloc(

0 commit comments

Comments
 (0)