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
$ ./build-for-web.sh wgpu
error: lto cannot be used for `proc-macro` crate type without `-Zdylib-lto`
error: could not compile `zerocopy-derive` (lib) due to 1 previous error
warning: build failed, waiting for other jobs to finish...
error: could not compile `walrus-macro` (lib) due to 1 previous error
error: could not compile `serde_derive` (lib) due to 1 previous error
error: failed to compile `wasm-bindgen-cli v0.2.92`, intermediate artifacts can be found at `/var/folders/sp/srxtqmsj43q17d8vhfjsbrdm0000gn/T/cargo-installeGnqzX`.
To reuse those artifacts with a future compilation, set the environment variable `CARGO_TARGET_DIR` to that path.
Error: Installing wasm-bindgen with cargo
Caused by: Installing wasm-bindgen with cargo
Caused by: failed to execute `cargo install`: exited with exit status: 101
full command: "cargo" "install" "--force" "wasm-bindgen-cli" "--root" "/Users/Library/Caches/.wasm-pack/.wasm-bindgen-cargo-install-0.2.92" "--version" "0.2.92"
To Reproduce
$ ./build-for-web.sh wgpu
When targeting ndarray, the result is the same, causes the same error.
Expected behavior
Successfully built.
Desktop (please complete the following information):
OS: macOS 14.4.1
Additional context
To resolve this issue, I propose removing the -C lto=fat option from RUSTFLAGS. This change will ensure compatibility with proc-macro crates and prevent the build errors. The link in the rust indicates lto cannot be used for proc-macro crate type without -Zdylib-lto, and -Zdylib-lto is not included in the standard rustc, the way I see it.
The text was updated successfully, but these errors were encountered:
Describe the bug
When building wasm to follow https://github.com/tracel-ai/burn/tree/main/examples/mnist-inference-web, it fails to build it as follows.
To Reproduce
When targeting ndarray, the result is the same, causes the same error.
Expected behavior
Successfully built.
Desktop (please complete the following information):
Additional context
To resolve this issue, I propose removing the -C lto=fat option from RUSTFLAGS. This change will ensure compatibility with proc-macro crates and prevent the build errors.
The link in the rust indicates lto cannot be used for
proc-macro
crate type without-Zdylib-lto
, and-Zdylib-lto
is not included in the standard rustc, the way I see it.The text was updated successfully, but these errors were encountered: