paritytech / substrate-contracts-node

Minimal Substrate node configured for smart contracts via pallet-contracts.
The Unlicense
124 stars 145 forks source link

error while compiling the substrate node #222

Closed Frankcastleauditor closed 9 months ago

Frankcastleauditor commented 9 months ago

I got this error after trying to install the substrate-contract-node :

1) I download rustc

rustc --version
rustc 1.75.0 (82e1608df 2023-12-21)

2) I cloned the repo

I followed the instruction to install substrate-contract-node here

git clone https://github.com/substrate-developer-hub/substrate-node-template

3) then I tried to compile the repo by this commands

git switch -c my-wip-branch
cargo build --release

and then I got this long error

failed to run custom build command for `sc-network-light v0.10.0-dev (https://github.com/paritytech/substrate.git?branch=polkadot-v1.0.0#948fbd2f)`

Caused by:
  process didn't exit successfully: `/home/mohamed/substrate-node-template/target/release/build/sc-network-light-0fea2d72bbd5faeb/build-script-build` (exit status: 101)
  --- stderr
  thread 'main' panicked at /home/mohamed/.cargo/registry/src/index.crates.io-6f17d22bba15001f/prost-build-0.11.9/src/lib.rs:1457:10:
  Could not find `protoc` installation and this build crate cannot proceed without
      this knowledge. If `protoc` is installed and this crate had trouble finding
      it, you can set the `PROTOC` environment variable with the specific path to your
      installed `protoc` binary.If you're on debian, try `apt-get install protobuf-compiler` or download it from https://github.com/protocolbuffers/protobuf/releases

  For more information: https://docs.rs/prost-build/#sourcing-protoc

  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...

so how can I fix this issue ?

cmichi commented 9 months ago

I followed the instruction to install substrate-contract-node here

You are linking to a page that is not referencing substrate-contracts-node and your description also refers to another node. Are you sure you want to install the node from this repository?

It seems you're rather looking for https://github.com/substrate-developer-hub/substrate-node-template?

Frankcastleauditor commented 9 months ago

I am sorry I got confused between the two repositories