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
This command is quite verbose, so you can create cargo config and Rust toolchain override files to make it shorter. Create a .cargo/config.toml file in the counter directory with the following contents:
[build]
target = "wasm32-unknown-unknown"
rustflags = [
"-C", "link-args=--import-memory",
"-C", "linker-plugin-lto",
]
And create a rust-toolchain.toml file in the counter directory with the following contents:
[toolchain]
channel = "stable"
targets = ["wasm32-unknown-unknown"]
profile = "default"
Now build your program with a single command:
cargo build --release
The text was updated successfully, but these errors were encountered:
failed
RUSTFLAGS="-C link-args=--import-memory -C linker-plugin-lto" \ cargo build --release --target=wasm32-unknown-unknown
This works
Quote:
This command is quite verbose, so you can create cargo config and Rust toolchain override files to make it shorter. Create a .cargo/config.toml file in the counter directory with the following contents:
[build]
target = "wasm32-unknown-unknown"
rustflags = [
"-C", "link-args=--import-memory",
"-C", "linker-plugin-lto",
]
The text was updated successfully, but these errors were encountered: