Open Ligang9 opened 1 week ago
You are not following either clang (llvm) or rustup target installation steps. Make sure your clang is up to date. Follow the steps in Building on Mac OS / Install llvm in the README; Make sure your environment variables are available in the process/terminal (by default, Mac OS can have an older clang installed, which will try to compile but doesn't have the required target available; when installing latest clang on MacOS it comes bundled with wasm32 target needed to build C sources of the secp256k1 crate). When installing the new version of the llvm
using brew
, if exports (env vars) are not set correctly, it won't see the newly installed version.
Also, check the info on the pre-built development releases at https://aspectron.org/en/projects/kaspa-wasm.html and https://github.com/aspectron/rusty-kaspa/blob/typescript/wasm/README.md
Once your clang issues are resolved, please use this if building from source: https://github.com/kaspanet/rusty-kaspa/pull/459
My computer is MacOS ./build-web Compiling secp256k1-sys v0.6.1 The following warnings were emitted during compilation:
warning: secp256k1-sys@0.6.1: error: unable to create target: 'No available targets are compatible with triple "wasm32-unknown-unknown"' warning: secp256k1-sys@0.6.1: 1 error generated.
error: failed to run custom build command for
secp256k1-sys v0.6.1
Caused by: process didn't exit successfully:
/Users/ligang/rusty-kaspa/target/release/build/secp256k1-sys-c339f6fad88f0367/build-script-build
(exit status: 1)