-
Notifications
You must be signed in to change notification settings - Fork 55
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
build ink-example /trait-dyn-cross-contract-calls fail #24
Comments
i modify the ink = { path = "../../../../crates/ink", default-features = false } to ink = { version = "4.2", default-features = false } that it can work |
Description =========== The build process for some contracts was failing due to issues in certain Cargo.toml files. Changes ======= - Commented out `crate-type` in `Cargo.toml` files. There's a conflict with this setting when using the updated version of the Ink contract compiler. - Added `no_main` attribute in `lib.rs`. This was missing in some contracts, and the updated version of the compiler is printing warning messages when it's missing. This commit addresses issue use-ink#24
Description =========== The build process for some contracts was failing due to issues in certain Cargo.toml files. Changes ======= - Commented out `crate-type` in `Cargo.toml` files. There's a conflict with this setting when using the updated version of the Ink contract compiler. - Added `no_main` attribute in `lib.rs`. This was missing in some contracts, and the updated version of the compiler is printing warning messages when it's missing. This commit addresses issue use-ink#24
Description =========== The build process for some contracts was failing due to issues in certain Cargo.toml files. Changes ======= - Commented out `crate-type` in `Cargo.toml` files. There's a conflict with this setting when using the updated version of the Ink contract compiler. - Added `no_main` attribute in `lib.rs`. This was missing in some contracts, and the updated version of the compiler is printing warning messages when it's missing. This commit addresses issue use-ink#24
Description =========== The build process for some contracts was failing due to issues in certain Cargo.toml files. Changes ======= - Commented out `crate-type` in `Cargo.toml` files. There's a conflict with this setting when using the updated version of the Ink contract compiler. - Added `no_main` attribute in `lib.rs`. This was missing in some contracts, and the updated version of the compiler is printing warning messages when it's missing. This commit addresses issue use-ink#24
Description =========== The build process for some contracts was failing due to issues in certain Cargo.toml files. Changes ======= - Commented out `crate-type` in `Cargo.toml` files. There's a conflict with this setting when using the updated version of the Ink contract compiler. - Added `no_main` attribute in `lib.rs`. This was missing in some contracts, and the updated version of the compiler is printing warning messages when it's missing. This commit addresses issue use-ink#24
Description =========== The build process for some contracts was failing due to issues in certain Cargo.toml files. Changes ======= - Commented out `crate-type` in `Cargo.toml` files. There's a conflict with this setting when using the updated version of the Ink contract compiler. - Added `no_main` attribute in `lib.rs`. This was missing in some contracts, and the updated version of the compiler is printing warning messages when it's missing. This commit addresses issue use-ink#24
fix: address build failures in some contracts (#24)
cd trait-dyn-cross-contract-calls/contracts/incrementer
cargo contract build
the error is :
Compiling trait-incrementer v4.0.0 (/private/var/folders/q3/qpr18mtx5pzdfzdp282189gw0000gn/T/cargo-contract_LdIgay/contracts/incrementer) error: the#[global_allocator]` in ink_allocator conflicts with global allocator in: ink_allocator
error[E0152]: duplicate lang item in crate ink_env (which ink depends on): panic_impl.
|
= note: the lang item is first defined in crate ink_env (which ink depends on)
= note: first definition in ink_env loaded from /Volumes/E/project/github.com/paritytech/ink-examples/trait-dyn-cross-contract-calls/target/ink/trait_incrementer/wasm32-unknown-unknown/release/deps/libink_env-732c71f7eb8a9501.rlib, /Volumes/E/project/github.com/paritytech/ink-examples/trait-dyn-cross-contract-calls/target/ink/trait_incrementer/wasm32-unknown-unknown/release/deps/libink_env-732c71f7eb8a9501.rmeta
= note: second definition in ink_env loaded from /Volumes/E/project/github.com/paritytech/ink-examples/trait-dyn-cross-contract-calls/target/ink/trait_incrementer/wasm32-unknown-unknown/release/deps/libink_env-d25c2c37eb82aaca.rlib, /Volumes/E/project/github.com/paritytech/ink-examples/trait-dyn-cross-contract-calls/target/ink/trait_incrementer/wasm32-unknown-unknown/release/deps/libink_env-d25c2c37eb82aaca.rmeta
`
the Cargo.toml is as follow; I modity the ink = { path = "/Volumes/E/project/github.com/paritytech/ink/crates/ink", default-features = false };
`
[package]
name = "trait-incrementer"
version = "4.0.0"
authors = ["Parity Technologies [email protected]"]
edition = "2021"
publish = false
[dependencies]
ink = { path = "/Volumes/E/project/github.com/paritytech/ink/crates/ink", default-features = false }
#ink = { path = "../../../../crates/ink", default-features = false }
`
So how can i build this contract。 @cmichi thanks
The text was updated successfully, but these errors were encountered: