Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Getting this error message while installing solana: error: failed to run custom build command for `prost-build v0.10.1`

I'm got this error after running this command: ./scripts/cargo-install-all.sh .

error: failed to run custom build command for `prost-build v0.10.1`

I'm installing solana on m1 mac Anyone please help me with this.

enter image description here

like image 243
r007 Avatar asked Oct 22 '25 23:10

r007


1 Answers

The prost-build crate compilation is failing because it can't find protocol-buffer implementation, and the crate build.rs tries to compile it via cmake (which you don't have installed).

I solved it by installing protocol-buffers directly, but since there are problems with the pre-compiled binary in M1 you have to compile it locally. It's simple:

git clone https://github.com/protocolbuffers/protobuf.git
cd protobuf

brew install autoconf
brew install automake
brew install Libtool

autoreconf -i
./autogen.sh
./configure
make
make check
sudo make install

export PATH=/opt/usr/local/bin:$PATH

This works!!!

like image 70
Antonio Estevez García Avatar answered Oct 25 '25 23:10

Antonio Estevez García



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!