You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Does not link env module when compiling libs with [no_std] #333
For what it’s worth, the compilation succeeds but the final output wasm imports the symbols "env" "memset" and "env" "memcpy".
To avoid this you can use RUSTFLAGS='-C target-feature=+bulk-memory' cargo component build to generate a wasip1 component which depends on the widely supported1 bulk memory operations.
Alternatively you can use cargo component build --target wasm32-unknown-unknown to generate a non Wasi component instead.
Activity
primoly commentedon Sep 11, 2024
For what it’s worth, the compilation succeeds but the final output wasm imports the symbols
"env" "memset"and"env" "memcpy".To avoid this you can use
RUSTFLAGS='-C target-feature=+bulk-memory' cargo component buildto generate awasip1component which depends on the widely supported1 bulk memory operations.Alternatively you can use
cargo component build --target wasm32-unknown-unknownto generate a non Wasi component instead.Footnotes
https://webassembly.org/features/ ↩