build: require sqlite when building the wallet

Require that sqlite is available in order to compile the wallet. Removes
instances of USE_SQLITE since it is no longer possible to not have
sqlite available.

The NO_SQLITE option is dropped from depends.

Co-authored-by: Ava Chow <github@achow101.com>
Co-authored-by: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com>
This commit is contained in:
Sjors Provoost
2025-03-12 15:42:38 +01:00
parent 502d47203e
commit 36b6f36ac4
40 changed files with 33 additions and 142 deletions

View File

@@ -3,7 +3,6 @@
// file COPYING or https://www.opensource.org/licenses/mit-license.php.
#include <bench/bench.h>
#include <bitcoin-build-config.h> // IWYU pragma: keep
#include <random.h>
#include <support/allocators/secure.h>
#include <test/util/setup_common.h>
@@ -61,9 +60,7 @@ static void WalletCreate(benchmark::Bench& bench, bool encrypted)
static void WalletCreatePlain(benchmark::Bench& bench) { WalletCreate(bench, /*encrypted=*/false); }
static void WalletCreateEncrypted(benchmark::Bench& bench) { WalletCreate(bench, /*encrypted=*/true); }
#ifdef USE_SQLITE
BENCHMARK(WalletCreatePlain, benchmark::PriorityLevel::LOW);
BENCHMARK(WalletCreateEncrypted, benchmark::PriorityLevel::LOW);
#endif
} // namespace wallet

View File

@@ -75,10 +75,8 @@ static void WalletIsMineLegacy(benchmark::Bench& bench) { WalletIsMine(bench, /*
BENCHMARK(WalletIsMineLegacy, benchmark::PriorityLevel::LOW);
#endif
#ifdef USE_SQLITE
static void WalletIsMineDescriptors(benchmark::Bench& bench) { WalletIsMine(bench, /*legacy_wallet=*/false); }
static void WalletIsMineMigratedDescriptors(benchmark::Bench& bench) { WalletIsMine(bench, /*legacy_wallet=*/false, /*num_combo=*/2000); }
BENCHMARK(WalletIsMineDescriptors, benchmark::PriorityLevel::LOW);
BENCHMARK(WalletIsMineMigratedDescriptors, benchmark::PriorityLevel::LOW);
#endif
} // namespace wallet

View File

@@ -73,8 +73,6 @@ static void WalletLoadingLegacy(benchmark::Bench& bench) { WalletLoading(bench,
BENCHMARK(WalletLoadingLegacy, benchmark::PriorityLevel::HIGH);
#endif
#ifdef USE_SQLITE
static void WalletLoadingDescriptors(benchmark::Bench& bench) { WalletLoading(bench, /*legacy_wallet=*/false); }
BENCHMARK(WalletLoadingDescriptors, benchmark::PriorityLevel::HIGH);
#endif
} // namespace wallet

View File

@@ -2,8 +2,6 @@
// Distributed under the MIT software license, see the accompanying
// file COPYING or https://www.opensource.org/licenses/mit-license.php.
#include <bitcoin-build-config.h> // IWYU pragma: keep
#include <bench/bench.h>
#include <kernel/chain.h>
#include <interfaces/chain.h>
@@ -17,8 +15,6 @@
#include <optional>
#if defined(USE_SQLITE) // only enable benchmark when sqlite is enabled
namespace wallet{
static void WalletMigration(benchmark::Bench& bench)
@@ -75,5 +71,3 @@ static void WalletMigration(benchmark::Bench& bench)
BENCHMARK(WalletMigration, benchmark::PriorityLevel::LOW);
} // namespace wallet
#endif // end USE_SQLITE && USE_BDB