Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

crate compiled by rustc 1.76.0, please recompile that crate using compiler rustc 1.76.0 #1380

Open
plavcik opened this issue Apr 12, 2024 · 0 comments

Comments

@plavcik
Copy link

plavcik commented Apr 12, 2024

I'm on OpenBSD 7.5 amd64 with

rustc -V
rustc 1.76.0 (07dca489a 2024-02-04) (built from a source tarball)

With wasm32-unknown-unknown from
https://static.rust-lang.org/dist/rust-std-1.76.0-wasm32-unknown-unknown.tar.gz

Cargo.toml have

[lib]
crate-type = ["cdylib", "rlib"]
cargo clean
cargo build
wasm-pack build
[INFO]: 🎯  Checking for the Wasm target...
[INFO]: 🌀  Compiling to Wasm...
   Compiling proc-macro2 v1.0.79
   Compiling unicode-ident v1.0.12
   Compiling wasm-bindgen-shared v0.2.92
   Compiling log v0.4.21
   Compiling bumpalo v3.15.4
   Compiling once_cell v1.19.0
   Compiling wasm-bindgen v0.2.92
   Compiling libc v0.2.153
   Compiling cfg-if v1.0.0
   Compiling autocfg v1.1.0
error[E0514]: found crate `core` compiled by an incompatible version of rustc
  |
  = note: the following crate versions were found:
          crate `core` compiled by rustc 1.76.0 (07dca489a 2024-02-04): /usr/local/lib/rustlib/wasm32-unknown-unknown/lib/libcore-f107444cd3cde330.rlib
  = help: please recompile that crate using this compiler (rustc 1.76.0 (07dca489a 2024-02-04) (built from a source tarball)) (consider running `cargo clean` first)

error[E0514]: found crate `compiler_builtins` compiled by an incompatible version of rustc
  |
  = note: the following crate versions were found:
          crate `compiler_builtins` compiled by rustc 1.76.0 (07dca489a 2024-02-04): /usr/local/lib/rustlib/wasm32-unknown-unknown/lib/libcompiler_builtins-5704ea1fcfcfa0d8.rlib
  = help: please recompile that crate using this compiler (rustc 1.76.0 (07dca489a 2024-02-04) (built from a source tarball)) (consider running `cargo clean` first)

For more information about this error, try `rustc --explain E0514`.
error: could not compile `cfg-if` (lib) due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
Error: Compiling your crate to WebAssembly failed
Caused by: Compiling your crate to WebAssembly failed
Caused by: failed to execute `cargo build`: exited with exit status: 101
  full command: cd $MY_PROJECT && "cargo" "build" "--lib" "--release" "--target" "wasm32-unknown-unknown"

Can I do something about

rustc 1.76.0 (07dca489a 2024-02-04) versus
rustc 1.76.0 (07dca489a 2024-02-04) (built from a source tarball)

Thank you,
Jiří

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant