Compilation Error : undefined reference to `boost::this_thread::hidden::sleep_for #13182

issue MaherBTA opened this issue on May 7, 2018
  1. MaherBTA commented at 1:27 AM on May 7, 2018: none

    Hi, I am trying to compile Bitcoin on Ubuntu 16 . I have installed correctly all the dependencies. the ./configure shows no errors, but when I run the make command :

    CXXLD bitcoind libbitcoin_util.a(libbitcoin_util_a-utiltime.o): In function boost::this_thread::sleep_for(boost::chrono::duration<long, boost::ratio<1l, 1000000000l> > const&)': /usr/local/include/boost/thread/pthread/thread_data.hpp:258: undefined reference to boost::this_thread::hidden::sleep_for(timespec const&)' collect2: error: ld returned 1 exit status Makefile:3712: recipe for target 'bitcoind' failed

    Also when I run ./configure --with-boost=/usr/local it returns :

    checking whether the Boost::Thread library is available... yes configure: error: Could not find a version of the boost_thread library!

  2. fanquake added the label Linux/Unix on May 7, 2018
  3. jonasschnelli commented at 12:11 PM on May 7, 2018: contributor

    Try to clean your project: git clean -dxf (removes all your local changes!) autogen.sh ./configure make -j

    If you still face the issue, please upload your config.log

  4. MaherBTA commented at 10:44 PM on May 7, 2018: none

    It is still showing the same error during make

    config.log

  5. iFoggz commented at 2:59 AM on May 8, 2018: none

    -with-boost-libdir=/usr/local/lib add that to configure line to try? This fedora or centos?

    On Mon, May 7, 2018, 3:45 PM Maher BEN, notifications@github.com wrote:

    It is still showing the same error during make

    config.log https://github.com/bitcoin/bitcoin/files/1981713/config.log

    — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/bitcoin/bitcoin/issues/13182#issuecomment-387229446, or mute the thread https://github.com/notifications/unsubscribe-auth/AMrVQElJ258ZcBJxKFnMHyZkjebdjMjSks5twM59gaJpZM4T0SLO .

  6. MaherBTA commented at 3:12 AM on May 8, 2018: none

    I am using Ubuntu 16. when I run the configure -with-boost-libdir=/usr/local/lib I get this error :

    checking whether the Boost::Thread library is available... yes configure: error: Could not find a version of the boost_thread library!

    also same error when passing -with-boost-libdir=/usr/local/ .

    boost is correctly installed, but there is a missing library, might it be something wrong with the boost version?

  7. MaherBTA commented at 8:55 PM on May 10, 2018: none

    Is there any good tutorial to compile bitcoin on Ubuntu ?

  8. MarcoFalke commented at 9:07 PM on May 10, 2018: member

    @MaherBTA There are steps in ./doc/build-*.md. E.g. doc/build-unix.md

  9. MarcoFalke commented at 9:09 PM on May 10, 2018: member

    Also, you could just "fall back" to using depends if you encounter issues. Those are almost guaranteed to work. See the depends subfolder.

  10. MaherBTA commented at 7:03 PM on May 12, 2018: none

    the issue was with boost. Bitcoin compilation works only with boost 1.64 not even another version. I tested like 5 boost versions . only the 1.64 worked for me. also installing boost with appitute will install the wrong version. Remark : in the dependencies.md the boost 1.64 href is linking to the 1.67 version.

  11. MaherBTA closed this on May 12, 2018

  12. 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