build: Drop boost-system dependency #21066

pull hebasto wants to merge 1 commits into bitcoin:master from hebasto:210202-system changing 9 files +7 −132
  1. hebasto commented at 1:04 PM on February 2, 2021: member

    There no reasons why the libboost-system-dev package could be required.

  2. fanquake added the label Build system on Feb 2, 2021
  3. hebasto force-pushed on Feb 2, 2021
  4. fanquake commented at 1:14 PM on February 2, 2021: member

    Concept ACK. I had been thinking about splitting this out of #20744.

    Does this work with Boost < 1.65.0?

    You'll also need to drop $BOOST_SYSTEM_LIB from BOOST_LIBS in configure.ac.

  5. fanquake commented at 1:28 PM on February 2, 2021: member

    Actually, I looked at this too quickly. This doesn't modify/remove any of the boost::system::error_code ec; usage in our code?

  6. hebasto marked this as a draft on Feb 2, 2021
  7. hebasto commented at 1:34 PM on February 2, 2021: member

    @fanquake

    Actually, I looked at this too quickly. This doesn't modify/remove any of the boost::system::error_code ec; usage in our code?

    $ git grep -n -e 'boost::system::error_code'
    src/wallet/db.cpp:17:    boost::system::error_code ec;
    src/wallet/db.cpp:81:    boost::system::error_code ec;
    src/wallet/db.cpp:105:    boost::system::error_code ec;
    src/wallet/load.cpp:23:        boost::system::error_code error
    

    Interesting, why I have no errors during compiling and cross-compiling with depends?

  8. build: Drop boost-system dependency 3ca25d9117
  9. hebasto force-pushed on Feb 2, 2021
  10. fanquake commented at 2:02 PM on February 2, 2021: member

    Interesting, why I have no errors during compiling and cross-compiling with depends?

    If you try and build using Boost < 1.69.0, it will fail to link (1f65eac0b809ca4441cfaa6c9da4b9d3e47581d3):

    make[2]: Leaving directory '/bitcoin'
      CXXLD    bitcoind
    /usr/bin/ld: bitcoind-bitcoind.o: undefined reference to symbol '_ZN5boost6system15system_categoryEv'
    //usr/lib/x86_64-linux-gnu/libboost_system.so.1.62.0: error adding symbols: DSO missing from command line
    collect2: error: ld returned 1 exit status
    Makefile:4980: recipe for target 'bitcoind' failed
    make[1]: *** [bitcoind] Error 1
    
      AR       libbitcoin_wallet.a
      CXXLD    bitcoind
    /usr/bin/ld: bitcoind-bitcoind.o: undefined reference to symbol '_ZN5boost6system15system_categoryEv'
    //usr/lib/x86_64-linux-gnu/libboost_system.so.1.65.1: error adding symbols: DSO missing from command line
    collect2: error: ld returned 1 exit status
    Makefile:4980: recipe for target 'bitcoind' failed
    make[1]: *** [bitcoind] Error 1
    

    See the Boost System revision history:

    Boost 1.69.0 Boost.System is now header-only. A stub library is still built for compatibility, but linking to it is no longer necessary.

  11. laanwj commented at 6:08 PM on February 2, 2021: member

    $ git grep -n -e 'boost::system::error_code'

    Right-I don't think getting rid of boost::system makes sense before boost::filesystem. The error codes from boost::system are used internally all over the place.

  12. hebasto commented at 6:17 PM on February 2, 2021: member

    Closing in favor of #20744.

  13. hebasto closed this on Feb 2, 2021

  14. DrahtBot commented at 6:37 PM on February 2, 2021: member

    <!--e57a25ab6845829454e8d69fc972939a-->

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    <!--174a7506f384e20aa4161008e828411d-->

    Conflicts

    Reviewers, this pull request conflicts with the following ones:

    • #21064 (refactor: use std::shared_mutex & remove Boost Thread by fanquake)
    • #20744 ([POC] Use std::filesystem. Remove Boost Filesystem & System by fanquake)
    • #16546 (External signer support - Wallet Box edition by Sjors)

    If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

  15. DrahtBot locked this on Aug 16, 2022

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-24 21:14 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me