[BUILD] Search and include OpenSSL only where required
Since D6242 there is no more OpenSSL needed outside of the BIP70
feature. This diff cleans up the build system to reflect this.
but obviously different because we maintain BIP70.
Depends on D6251.
ninja all check-all bench-bitcoin make make check
Run the Gitian builds.
Uninstall OpenSSL (or make it fail to be found), then:
cmake -GNinja .. \ -DENABLE_BIP70=OFF \ -DSECP256K1_BUILD_OPENSSL_TESTS=OFF ninja all check-all
With autotools, the whole secp256k1 test suite should be disabled in
order to skip openssl detection. Unfortunately the option name collides
with the bitcoin abc option to disable the tests, so they end up to be
../configure \ --enable-deprecated-build-system \ --disable-bip70 \ --enable-tests=no make
Reviewers: #bitcoin_abc, deadalnix
Reviewed By: #bitcoin_abc, deadalnix
Differential Revision: https://reviews.bitcoinabc.org/D6243