[Docs] Create NetBSD build instructions and fix compilation #12294

pull fanquake wants to merge 3 commits into bitcoin:master from fanquake:netbsd-build-docs changing 3 files +53 −1
  1. fanquake commented at 1:19 PM on January 29, 2018: member

    Replaces #12125.

  2. [build] Add db4_cxx to bitcoin_find_bdb48.m4
    Added "db4_cxx" as this is the name used in NetBSD for the Berkeley DB library.  Without this additional base filename alternative, the "configure" script will fail to find this library and compilation will not succeed.
    336685e17e
  3. fanquake added the label Docs on Jan 29, 2018
  4. fanquake added the label Linux/Unix on Jan 29, 2018
  5. randolf commented at 5:56 PM on January 29, 2018: contributor

    @fanquake Thank you for your help with this. I appreciate it.

  6. theuni commented at 7:31 PM on January 29, 2018: member

    Thanks @fanquake :)

  7. in doc/build-netbsd.md:40 in 4506e4282c outdated
      35 | +**Important**: Use `gmake` (the non-GNU `make` will exit with an error).
      36 | +
      37 | +With wallet:
      38 | +```
      39 | +./autogen.sh
      40 | +./configure CPPFLAGS="-I/usr/pkg/include -DOS_NETBSD" LDFLAGS="-L/usr/pkg/lib" BOOST_CPPFLAGS="-I/usr/pkg/include" BOOST_LDFLAGS="-L/usr/pkg/lib"
    


    theuni commented at 7:33 PM on January 29, 2018:

    Could you please add this: #12125 (comment)

    Then -DOS_NETBSD shouldn't be needed, which I suspect is enough to fix the upstream package.


    theuni commented at 7:34 PM on January 29, 2018:

    Are the BOOST_CPPFLAGS really needed in addition to CPPFLAGS ? If so, that'd be a bug imo.


    randolf commented at 7:48 PM on January 29, 2018:

    @theuni Unfortunately, these flags are needed, I suspect due to the way Boost is installed on NetBSD via the "pkgin" system (as I understand it, the Boost project has a few peculiarities that add complexity). Without these flags, the Bitcoin software won't build/compile successfully.


    randolf commented at 7:52 PM on January 29, 2018:

    @theuni As I recall, the -DOS_NETBSD flag is needed because the Makefiles and various other scripts seem to have problems detecting the OS reliably, and sometimes the issue is with case-sensitivity. The inclusion of this flag results in a successful build/compile, but if it's possible to update the needed files to eliminate this then I think that would be excellent.


    theuni commented at 8:10 PM on January 29, 2018:

    Could you please paste the error when trying to build without BOOST_CPPFLAGS / BOOST_LDFLAGS set?

    It sounds like some of the checks are clobbering the usual flags. If that's the case, I'd rather fix it than work around it.


    theuni commented at 8:20 PM on January 29, 2018:

    Yes, it's needed for leveldb. We detect it for other OSs, there's no need to tream netbsd differently in this regard.

  8. [doc] Create build-netbsd.md 1944fa3205
  9. [build] Add NETBSD leveldb target to configure.ac 11c5827ca7
  10. fanquake force-pushed on Jan 29, 2018
  11. fanquake commented at 11:51 PM on January 29, 2018: member

    @theuni Added the leveldb target to configure.ac, and dropped -DOS_NETBSD from the install instructions.

  12. randolf commented at 2:37 AM on January 30, 2018: contributor

    @fanquake I would like to test your changes on my system, but the various instructions I found for merging in an open pull request are all failing for me. What "git" command should I use after/with/instead-of "git clone?" Thanks.

  13. fanquake commented at 3:50 AM on January 30, 2018: member

    @randolf Try using the github-merge.py script. You can pass it the PR number, 12294 in this case, and it will merge the changes for you.

  14. randolf commented at 5:27 AM on January 30, 2018: contributor

    @fanquake That looks like it could be useful, but I couldn't get it working (error text indicates that I need to run "git config githubmerge.repository <owner>/<repo>" and the few things I guessed at did not work), so due to limited time I simply downloaded the two modified files (plus the new document) and merged them manually.

    I'll post results here after attempting to run with the instructions that include your updates.

  15. randolf commented at 5:51 AM on January 30, 2018: contributor

    @fanquake The build/compile process was successful on NetBSD 7.0 (amd64).

    This is what I did: I cloned bitcoin/bitcoin, then I manually downloaded the three files from this Pull Request and merged them in manually. After that, I followed the build/compile instructions in doc/build-netbsd.md (which came from this Pull Request). The end result was that bitcoind and various other binaries had been created, as expected, without the process ending abnormally, and so I consider this to be a successful build/compile.

    Thank you for your help.

  16. laanwj commented at 8:57 AM on January 30, 2018: member

    utACK 11c5827, thanks for porting this @fanquake and for testing @randolf

  17. laanwj merged this on Jan 30, 2018
  18. laanwj closed this on Jan 30, 2018

  19. laanwj referenced this in commit 7cf1aea5cf on Jan 30, 2018
  20. randolf commented at 5:45 PM on January 30, 2018: contributor

    @laanwj I appreciate the help from @fanquake to get my original PR "squashed" because I'm still learning how to use this GitHub system. I'm delighted to have had this chance to contribute to Bitcoin, and I'm interested in contributing more in the future.

  21. fanquake deleted the branch on Jan 31, 2018
  22. laanwj referenced this in commit 216f9a42e6 on Jan 31, 2018
  23. zkbot referenced this in commit ce5d8daae6 on Jan 25, 2021
  24. PastaPastaPasta referenced this in commit 38c60bc2f5 on Jun 26, 2021
  25. PastaPastaPasta referenced this in commit 8878ae64e3 on Jun 26, 2021
  26. MarcoFalke locked this on Sep 8, 2021

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-13 15:15 UTC

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