error: #error "Bitcoin cannot be compiled without assertions." #15499

issue jiapei100 opened this issue on February 28, 2019
  1. jiapei100 commented at 5:16 AM on February 28, 2019: none

    Hi, all:

    My ENV: Ubuntu 18.04.2 Qt 5.12.1 bitcoin: git master of the day Feb 27, 2019.

    My configuration is:

    $ export PKG_CONFIG_PATH=/opt/Qt/Current/gcc_64/lib/pkgconfig
    $ ./configure --with-incompatible-bdb --enable-gprof=yes -with-gui=yes  --with-boost-libdir=/usr/lib --with-boost-system=boost_system --with-boost-filesystem=boost_filesystem --with-boost-thread=boost_thread --with-boost-chrono=boost_chrono --with-boost-unit-test-framework=boost_unit_test_framework
    

    If --with-gui=no, I can successfully build bitcoin. However, by enabling gui/qt, I obtained the following ERROR messages:

    In file included from ./util/system.h:19,
                     from ./dbwrapper.h:12,
                     from ./txdb.h:10,
                     from ./test/test_bitcoin.h:14,
                     from ./wallet/test/wallet_test_fixture.h:8,
                     from wallet/test/wallet_test_fixture.cpp:5:
    ./compat/assumptions.h:17:3: error: #error "Bitcoin cannot be compiled without assertions."
     # error "Bitcoin cannot be compiled without assertions."
       ^~~~~
    In file included from ./util/system.h:19,
                     from ./dbwrapper.h:12,
                     from ./txdb.h:10,
                     from ./test/test_bitcoin.h:14,
                     from test/test_bitcoin.cpp:5:
    ./compat/assumptions.h:17:3: error: #error "Bitcoin cannot be compiled without assertions."
     # error "Bitcoin cannot be compiled without assertions."
       ^~~~~
      CXX      crypto/libbitcoinconsensus_la-siphash.lo
      CXX      crypto/libbitcoinconsensus_la-sha256_sse4.lo
      CXX      libbitcoinconsensus_la-arith_uint256.lo
      CXX      consensus/libbitcoinconsensus_la-merkle.lo
      CXX      libbitcoinconsensus_la-hash.lo
      CXX      primitives/libbitcoinconsensus_la-block.lo
      CXX      primitives/libbitcoinconsensus_la-transaction.lo
      CXX      libbitcoinconsensus_la-pubkey.lo
    In file included from ./wallet/walletdb.h:12,
                     from ./wallet/wallet.h:23,
                     from ./wallet/test/wallet_test_fixture.h:12,
                     from wallet/test/wallet_test_fixture.cpp:5:
    ./wallet/db.h: In destructor ‘BerkeleyDatabase::~BerkeleyDatabase()’:
    ./wallet/db.h:129:20: warning: unused variable ‘erased’ [-Wunused-variable]
                 size_t erased = env->m_databases.erase(strFile);
                        ^~~~~~
      CXX      script/libbitcoinconsensus_la-bitcoinconsensus.lo
      CXX      script/libbitcoinconsensus_la-interpreter.lo
    make[2]: *** [Makefile:10957: test/qt_test_test_bitcoin_qt-test_bitcoin.o] Error 1
    make[2]: *** Waiting for unfinished jobs....
    make[2]: *** [Makefile:10999: wallet/test/qt_test_test_bitcoin_qt-wallet_test_fixture.o] Error 1
    make[2]: Leaving directory '....../bitcoingui/src'
    make[1]: *** [Makefile:12939: all-recursive] Error 1
    make[1]: Leaving directory '....../bitcoingui/src'
    make: *** [Makefile:774: all-recursive] Error 1
    

    Any suggestions?

  2. sipa commented at 5:29 AM on February 28, 2019: member

    Yes, disable NDEBUG.

  3. sipa closed this on Feb 28, 2019

  4. fanquake added the label Questions and Help on Feb 28, 2019
  5. HeidiRomeroCash commented at 5:45 PM on May 7, 2019: none

    What are assertions 😰

    On Wed, Feb 27, 2019, 9:30 PM Pieter Wuille notifications@github.com wrote:

    Closed #15499 https://github.com/bitcoin/bitcoin/issues/15499.

    — 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/15499#event-2170014545, or mute the thread https://github.com/notifications/unsubscribe-auth/AhGFkduanYgMaKXxwXTIKOk5Y-eVlvHeks5vR2mKgaJpZM4bWB5- .

  6. MarcoFalke locked this on Dec 16, 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-26 06:14 UTC

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