Fail to build on fedora 32

I’m trying to build on Fedora following the guide, as usual.

I had to install “make” since missing. Would be good to add it in the dependencies.

Then building process stops here: >

make[3]: Leaving directory ‘/home/den/zcash/src/secp256k1’
CXX zcash/libzcash_a-Address.o
In file included from crypto/equihash.cpp:20:
./crypto/equihash.h: In function ‘bool EhBasicSolve(unsigned int, unsigned int, const eh_HashState&, std::function<bool(std::vector)>, std::function<bool(EhSolverCancelCheck)>)’:
./crypto/equihash.h:230:20: error: ‘invalid_argument’ is not a member of ‘std’
230 | throw std::invalid_argument(“Unsupported Equihash parameters”);
| ^~~~~~~~~~~~~~~~
./crypto/equihash.h: In function ‘bool EhOptimisedSolve(unsigned int, unsigned int, const eh_HashState&, std::function<bool(std::vector)>, std::function<bool(EhSolverCancelCheck)>)’:
./crypto/equihash.h:254:20: error: ‘invalid_argument’ is not a member of ‘std’
254 | throw std::invalid_argument(“Unsupported Equihash parameters”);
| ^~~~~~~~~~~~~~~~
make[2]: *** [Makefile:3186: crypto/libbitcoin_crypto_a-equihash.o] Error 1
make[2]: *** Waiting for unfinished jobs…
make[2]: Leaving directory ‘/home/den/zcash/src’
make[1]: *** [Makefile:6606: all-recursive] Error 1
make[1]: Leaving directory ‘/home/den/zcash/src’
make: *** [Makefile:637: all-recursive] Error 1

Can anybody help?

I’m not sure that Zcash is compatible with 32bit OS. You may want to check the documentation:

https://zcash.readthedocs.io/en/latest/

I think this is related to the latest Fedora, which is 32. Fedora itself dropped 32-bit support for x86 processors in Fedora 31.

1 Like

FWIW I can replicate this error building on Fedora 32.

1 Like

std::invalid_argument is defined in the <stdexcept> header: https://en.cppreference.com/w/cpp/error/invalid_argument

That header is being included in crypto/equihash.h: https://github.com/zcash/zcash/blob/1192116598253276e920ee164fe32547ef68dc25/src/crypto/equihash.h#L16

So I’m not sure what is going on here.

2 Likes