-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathInk_smart_contract.txt
40 lines (24 loc) · 1.07 KB
/
Ink_smart_contract.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
set up environment:
rustup default stable
rustup update
rustup update nightly
rustup target add wasm32-unknown-unknown --toolchain nightly
I am using mac, so install brew first:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
follow the tutorial and then install:
brew install binaryen
and then install another two dependencies:
cargo install cargo-dylint dylint-link
The previous command failed, and I fix it by install:
brew install openssl
and then:
cargo install cargo-contract --force --locked
If you get error:
cargo +nightly contract build
error: toolchain 'nightly-aarch64-apple-darwin' is not installed
Use this to fix it:
rustup toolchain install nightly
cargo install cargo-contract --version 2.0.0-rc
and the cargo lock file is not there, I used: rustup component add rust-src --toolchain nightly-aarch64-apple-darwin
I am learning from : https://www.youtube.com/watch?v=8ij_lhFpJaI and https://github.com/AstarNetwork/ink-xvm-sdk
This is also a great tutorial: https://www.crowdcast.io/c/astar-tech-talk-006-wasm-nfts