Top-level cargo call fails
cargo build --target wasm32-unknown-unknown
fails with the following error:
error[E0152]: found duplicate lang item `panic_impl`
--> installer_kernel/src/lib.rs:137:1
|
137 | fn panic(_info: &PanicInfo) -> ! {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: the lang item is first defined in crate `std` (which `kernel` depends on)
= note: first definition in `std` loaded from /home/lthms/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/wasm32-unknown-unknown/lib/libstd-c577f44da5fab0be.rlib
= note: second definition in the local crate (`tezos_rollup_installer_kernel`)
For more information about this error, try `rustc --explain E0152`.
error: could not compile `tezos_rollup_installer_kernel` due to previous error
But when passed explicitly a crate to build (using -p
), then it works well.
cargo build --target wasm32-unknown-unknown -p tezos_rollup_installer_kernel
Edited by Thomas Letan