Page MenuHomePhabricator

[backport#15638] [build] Move wallet load functions to wallet/load unit
ClosedPublic

Authored by majcosta on May 7 2020, 18:38.

Details

Summary

Moves the following wallet load functions to a new wallet/load unit in
the libbitcoin_wallet library. All other functions in wallet/init remain
in libbitcoin_server:

  • VerifyWallets
  • LoadWallets
  • StartWallets
  • FlushWallets
  • StopWallets
  • UnloadWallets

https://github.com/bitcoin/bitcoin/pull/15638/commits/9eaeb7fb8d4ab0d4493849e6c17e314fd75fea9c


Depends on D5997

This is a partial backport of Core PR15638

Test Plan
../configure --enable-deprecated-build-system [--disable-wallet]
make check
./test/functional/test_runner.py

../cmake -GNinja [-DBUILD_BITCOIN_WALLET=OFF]
ninja check-all

Diff Detail

Event Timeline

majcosta requested review of this revision.May 7 2020, 18:38

[Bot Message]
One or more PR numbers were detected in the summary.
Links to those PRs have been inserted into the summary for reference.

majcosta edited the summary of this revision. (Show Details)
deadalnix requested changes to this revision.May 7 2020, 19:27
deadalnix added a subscriber: deadalnix.

cmake build is wrong.

This revision now requires changes to proceed.May 7 2020, 19:27
nakihito requested changes to this revision.May 7 2020, 19:33
nakihito added a subscriber: nakihito.

Small nit and test plan should include autotools build:

../configure -enable-deprecated-build-system
make check
src/wallet/load.cpp
82 ↗(On Diff #19809)

Newline between the functions here.

corrected CMake build, test plan and formatting issues

deadalnix requested changes to this revision.May 8 2020, 21:22
deadalnix added inline comments.
This revision now requires changes to proceed.May 8 2020, 21:22

used target_sources() instead of ugly hack, hat tip @deadalnix

deadalnix requested changes to this revision.May 9 2020, 19:26
deadalnix added inline comments.
src/CMakeLists.txt
571 ↗(On Diff #19860)

Put that somewhere where the code make logical "paragraphs".

Also, the cmake build is still broken.

This revision now requires changes to proceed.May 9 2020, 19:26

contained cmake build changes to wallet/CMakeLists.txt

deadalnix added inline comments.
src/wallet/CMakeLists.txt
12 ↗(On Diff #19866)

Adding a comment would be helpful, but that works.

This revision is now accepted and ready to land.May 10 2020, 18:33