Currently, if you build depends using NO_BDB=1
(only sqlite wallets), ./configure
will fail as it still tries to find bdb. i.e:
0make -C depends/ NO_QT=1 NO_BDB=1 NO_UPNP=1 NO_ZMQ=1 NO_NATPMP=1 -j8
1...
2copying packages: native_b2 boost libevent sqlite
3
4./autogen.sh
5./configure --prefix=/home/ubuntu/bitcoin/depends/x86_64-pc-linux-gnu
6...
7checking for Berkeley DB C++ headers... default
8configure: error: Found Berkeley DB other than 4.8, required for portable BDB wallets (--with-incompatible-bdb to ignore or --without-bdb to disable BDB wallet support)
This PR fixes the build such that you can build depends, opting out of bdb, without opting out of wallets entirely, and still configure successfully. I think I’ve tested across most potential configurations. i.e:
0 ./configure (bdb and sqlite on system)
1 bdb & sqlite are both are available
2
3./configure --without-bdb (bdb and sqlite on system)
4 only sqlite
5
6./configure --without-sqlite (bdb and sqlite on system)
7 only bdb
8
9./configure --disable-wallet (bdb and sqlite on system)
10 neither bdb or sqlite
11
12depends NO_WALLET=1
13./configure --prefix=/bitcoin/depends/x86_64-apple-darwin19.6.0
14 neither bdb or sqlite
15
16depends NO_BDB=1
17./configure --prefix=/bitcoin/depends/x86_64-apple-darwin19.6.0
18 only sqlite
19
20depends NO_SQLITE=1
21./configure --prefix=/bitcoin/depends/x86_64-apple-darwin19.6.0
22 only bdb
23
24depends
25./configure --prefix=/bitcoin/depends/x86_64-apple-darwin19.6.0
26 bdb and sqlite