Open Geordi7 opened 3 years ago
Added note: I reproduced this error with rustc 1.56.0 on a M1 MacOS host and an i86_x86 Win10 host
OK... I solved it... but it was awkward
First: running cargo make
doesn't work, you have to run cargo make serve
so that it correctly sets the feature flags. It might be nice to have a cargo make web
option to just do the build and not run the server. Also cargo make
should emit an explicit error to the user given that the build will definitely fail.
After figuring that out I ran into the problem in issue #12, which happens because wasm-bindgen-cli
's latest version is later than the version referenced in bevy_webgl2
.
I ran cargo install wasm-bindgen-cli --version 0.2.69
, after which it built successfully. I got this idea because the Cargo.toml
of bevy_webgl2
specifies this version of wasm-bindgen
.
Just Realized I closed this issue, but no changes were made to fix it...
Please update the readme to clearly state that cargo make
doesn't work, and add a note about setting the version of wasm-bindgen-cli
to match the wasm-bindgen
version of bevy_webgl2
.
Can you check again? It should do local installation of proper wasm-bindgen-cli version. Dependencies are also fixed (it should not try to compilee bevy-webgl2 on non-wasm32 platforms), but I tested that only on linux machine so far.
I did a fresh clone and
cargo make
and it gets stuck on this error:I thought the issue might be in
bevy_webgl2
, but I cloned it and switched to thev0.5
branch andcargo make
succeeds.I also tried switching the dependency version to v0.5.2, it did not fix the issue.
I looked through the features flags for both projects, and I tried copying over the
winit
dependency specifier, it did not fix the issue.I could not think of something else to try.