bitcoin icon indicating copy to clipboard operation
bitcoin copied to clipboard

cmake + Nix/NixOS compatibility

Open 0xB10C opened this issue 1 year ago • 20 comments

I've looked into compatibility between the cmake-staging branch and Nix/NixOS packaging. I'm using this issue as an tracking issue, let me know if I should move it somewhere else.

Specifically, looking at the following:

  1. nixpkgs: changes required for a cmake build of the Nix bitcoin (with GUI) and bitcoind (without GUI) packages based on https://github.com/NixOS/nixpkgs/blob/nixos-23.11/pkgs/applications/blockchains/bitcoin/default.nix. This uses Nix depends.
  2. gunix: changes required for a cmake build of a full depends build (as we do in GUIX). I've been hacking on this in https://github.com/0xB10C/bitcoind-gunix/issues/1. The latest I've been able to build is 25.0, but haven't spent too much time on it.

I'm only testing x86_64-linux at the moment.

1. nixpkgs on x86_64-linux

Building 5e65a38896525cdb84f25e0968cc230e147cfc9b with the following patch to the bitcoin/default.nix file seems to mostly work. It fails during the installation of the bash completions, likely because the relative bash completions path isn't compatible with Nix. I can investigate what's needed here. Note that the nixpkgs version has it's own install of the bash completions. If we can skip these in the install phase, that might be an option.

diff --git a/pkgs/applications/blockchains/bitcoin/default.nix b/pkgs/applications/blockchains/bitcoin/default.nix
index f31fea152..c804bf0c9 100644
--- a/pkgs/applications/blockchains/bitcoin/default.nix
+++ b/pkgs/applications/blockchains/bitcoin/default.nix
@@ -1,7 +1,7 @@
 { lib
 , stdenv
 , fetchurl
-, autoreconfHook
+, cmake
 , pkg-config
 , installShellFiles
 , util-linux
@@ -33,18 +33,17 @@ let
 in
 stdenv.mkDerivation rec {
   pname = if withGui then "bitcoin" else "bitcoind";
-  version = "26.0";
-
+  version = "5e65a38896525cdb84f25e0968cc230e147cfc9b";
   src = fetchurl {
     urls = [
-      "https://bitcoincore.org/bin/bitcoin-core-${version}/bitcoin-${version}.tar.gz"
+      "https://github.com/hebasto/bitcoin/archive/${version}.tar.gz"
     ];
     # hash retrieved from signed SHA256SUMS
-    sha256 = "ab1d99276e28db62d1d9f3901e85ac358d7f1ebcb942d348a9c4e46f0fcdc0a1";
+    sha256 = "sha256-rKfPjUTmyVIJ2Sy8aETA12eXkzcGDy/Rbrj10rNeNj8=";
   };

   nativeBuildInputs =
-    [ autoreconfHook pkg-config installShellFiles ]
+    [ cmake pkg-config installShellFiles ]
     ++ lib.optionals stdenv.isLinux [ util-linux ]
     ++ lib.optionals stdenv.isDarwin [ hexdump ]
     ++ lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [ autoSignDarwinBinariesHook ]
...
[ 82%] Built target fuzz
[ 83%] Built target bitcoin-qt
[ 84%] Built target test_bitcoin-qt
[100%] Built target test_bitcoin
Install the project...
-- Install configuration: "Release"
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/bin/bitcoin-qt
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/bin/test_bitcoin-qt
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/bin/bench_bitcoin
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/bin/test_bitcoin
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/bin/bitcoin-wallet
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/bin/bitcoind
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/bin/bitcoin-cli
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/bin/bitcoin-tx
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/bin/bitcoin-util
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/share/man/man1
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/share/man/man1/bitcoin-tx.1
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/share/man/man1/bitcoin-wallet.1
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/share/man/man1/bitcoin-cli.1
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/share/man/man1/bitcoind.1
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/share/man/man1/bitcoin-util.1
-- Installing: /nix/store/4620r11377c07s7fxv87683x3bwral71-bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/share/man/man1/bitcoin-qt.1
install: cannot stat 'contrib/completions/bash/bitcoin-cli.bash': No such file or directory

Full build.log

2. depends build on x86_64-linux

Will update once I have a v26.0 build working and get to cmake. See https://github.com/0xB10C/bitcoind-gunix/issues/1#issuecomment-2001959293.

0xB10C avatar Mar 16 '24 11:03 0xB10C

2. depends build on x86_64-linux

With a normal v26.0 build working, I've been trying to build the cmake-staging branch from depends. I managed to get cmake to a point where it detects the depends Boost with -DBOOST_INCLUDEDIR=${depends}/include/ in https://github.com/0xB10C/bitcoind-gunix/commit/c4cb9f4e115b0e020f49aa1b3a283d20b3d187b9. However, having less luck with libevent. How do I tell cmake where to find the depends?

-- Checking for module 'libevent>=2.1.8'
--   No package 'libevent' found
CMake Error at /nix/store/pd8xc32hmc9sn70cc25x67ly90lby26j-cmake-3.25.3/share/cmake-3.25/Modules/FindPkgConfig.cmake:607 (message):
  A required package was not found
Call Stack (most recent call first):
  /nix/store/pd8xc32hmc9sn70cc25x67ly90lby26j-cmake-3.25.3/share/cmake-3.25/Modules/FindPkgConfig.cmake:829 (_pkg_check_modules_internal)
  cmake/module/CrossPkgConfig.cmake:43 (pkg_check_modules)
  cmake/module/AddLibeventIfNeeded.cmake:45 (cross_pkg_check_modules)
  CMakeLists.txt:274 (add_libevent_if_needed)


-- Configuring incomplete, errors occurred!
See also "/build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/build/CMakeFiles/CMakeOutput.log".
error: builder for '/nix/store/clh5fd5lg5j2pb76kqy5fwk5fhbwpr34-bitcoind.drv' failed with exit code 1;

https://github.com/0xB10C/bitcoind-gunix/actions/runs/8331185657/job/22797482552#step:6:285

0xB10C avatar Mar 18 '24 17:03 0xB10C

I'm not familiar with Nix, unfortunately.

@0xB10C

Can you post here boost and libevent installation directory structures?

hebasto avatar Mar 20 '24 17:03 hebasto

CMake Error at /nix/store/pd8xc32hmc9sn70cc25x67ly90lby26j-cmake-3.25.3/share/cmake-3.25/Modules/FindPkgConfig.cmake:607 (message):
  A required package was not found
Call Stack (most recent call first):
  /nix/store/pd8xc32hmc9sn70cc25x67ly90lby26j-cmake-3.25.3/share/cmake-3.25/Modules/FindPkgConfig.cmake:829 (_pkg_check_modules_internal)
  cmake/module/CrossPkgConfig.cmake:43 (pkg_check_modules)
  cmake/module/AddLibeventIfNeeded.cmake:45 (cross_pkg_check_modules)
  CMakeLists.txt:274 (add_libevent_if_needed)

~This shows that the pkg-config package is required.~

hebasto avatar Mar 20 '24 17:03 hebasto

CMake Error at /nix/store/pd8xc32hmc9sn70cc25x67ly90lby26j-cmake-3.25.3/share/cmake-3.25/Modules/FindPkgConfig.cmake:607 (message):
  A required package was not found
Call Stack (most recent call first):
  /nix/store/pd8xc32hmc9sn70cc25x67ly90lby26j-cmake-3.25.3/share/cmake-3.25/Modules/FindPkgConfig.cmake:829 (_pkg_check_modules_internal)
  cmake/module/CrossPkgConfig.cmake:43 (pkg_check_modules)
  cmake/module/AddLibeventIfNeeded.cmake:45 (cross_pkg_check_modules)
  CMakeLists.txt:274 (add_libevent_if_needed)

This shows that the pkg-config package is required.

I'm not that this complains pkg-config is missing. Dropping pkg-config from the build environment produces the following which is closer to what I'm expecting if pkg-config would actually be missing.

CMake Error at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)
Call Stack (most recent call first):
  /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindPackageHandleStandardArgs.cmake:600 (_FPHSA_FAILURE_MESSAGE)
  /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindPkgConfig.cmake:99 (find_package_handle_standard_args)
  cmake/module/CrossPkgConfig.cmake:5 (find_package)
  cmake/module/AddLibeventIfNeeded.cmake:44 (include)
  CMakeLists.txt:274 (add_libevent_if_needed)

edit: it also says this in the line above (not copied here)

-- Found PkgConfig: /nix/store/3ck7yhjzm3h5m3984ni6mj6nbq4saya0-pkg-config-wrapper-0.29.2/bin/pkg-config (found version "0.29.2")

0xB10C avatar Mar 20 '24 21:03 0xB10C

Can you post here boost and libevent installation directory structures?

boost and libevent are build from depends and are symlinked into depends/x86_64-pc-linux-gnu/. tree -L 2 of this directory is:

long tree output
├── bin
│   ├── event_rpcgen.py
│   ├── fc-cache
│   ├── fc-cat
│   ├── fc-list
│   ├── fc-match
│   ├── fc-pattern
│   ├── fc-query
│   ├── fc-scan
│   └── fc-validate
├── etc
│   └── fonts
├── include
│   ├── boost
│   ├── db_cxx.h
│   ├── db.h
│   ├── event2
│   ├── expat_config.h
│   ├── expat_external.h
│   ├── expat.h
│   ├── fontconfig
│   ├── freetype2
│   ├── getgateway.h
│   ├── miniupnpc
│   ├── natpmp_declspec.h
│   ├── natpmp.h
│   ├── qrencode.h
│   ├── QtAccessibilitySupport
│   ├── QtCore
│   ├── QtDBus
│   ├── QtDeviceDiscoverySupport
│   ├── QtEdidSupport
│   ├── QtEventDispatcherSupport
│   ├── QtFbSupport
│   ├── QtFontDatabaseSupport
│   ├── QtGui
│   ├── qtharfbuzz
│   ├── QtInputSupport
│   ├── qtlibpng
│   ├── QtNetwork
│   ├── QtPlatformHeaders
│   ├── QtServiceSupport
│   ├── QtTest
│   ├── QtThemeSupport
│   ├── QtWidgets
│   ├── QtXkbCommonSupport
│   ├── QtZlib
│   ├── sqlite3ext.h
│   ├── sqlite3.h
│   ├── sys
│   ├── wingettimeofday.h
│   ├── X11
│   ├── xcb
│   ├── xkbcommon
│   ├── zmq.h
│   └── zmq_utils.h
├── lib
│   ├── cmake
│   ├── libdb-4.8.a
│   ├── libdb.a
│   ├── libdb_cxx-4.8.a
│   ├── libdb_cxx.a
│   ├── libevent.a
│   ├── libevent_core.a
│   ├── libevent_extra.a
│   ├── libevent_pthreads.a
│   ├── libexpat.a
│   ├── libfontconfig.so -> libfontconfig.so.1.10.1
│   ├── libfontconfig.so.1 -> libfontconfig.so.1.10.1
│   ├── libfontconfig.so.1.10.1
│   ├── libfreetype.so -> libfreetype.so.6.18.0
│   ├── libfreetype.so.6 -> libfreetype.so.6.18.0
│   ├── libfreetype.so.6.18.0
│   ├── libminiupnpc.a
│   ├── libnatpmp.a
│   ├── libqrencode.a
│   ├── libQt5AccessibilitySupport.a
│   ├── libQt5AccessibilitySupport.prl
│   ├── libQt5Core.a
│   ├── libQt5Core.prl
│   ├── libQt5DBus.a
│   ├── libQt5DBus.prl
│   ├── libQt5DeviceDiscoverySupport.a
│   ├── libQt5DeviceDiscoverySupport.prl
│   ├── libQt5EdidSupport.a
│   ├── libQt5EdidSupport.prl
│   ├── libQt5EventDispatcherSupport.a
│   ├── libQt5EventDispatcherSupport.prl
│   ├── libQt5FbSupport.a
│   ├── libQt5FbSupport.prl
│   ├── libQt5FontDatabaseSupport.a
│   ├── libQt5FontDatabaseSupport.prl
│   ├── libQt5Gui.a
│   ├── libQt5Gui.prl
│   ├── libQt5InputSupport.a
│   ├── libQt5InputSupport.prl
│   ├── libQt5Network.a
│   ├── libQt5Network.prl
│   ├── libQt5ServiceSupport.a
│   ├── libQt5ServiceSupport.prl
│   ├── libQt5Test.a
│   ├── libQt5Test.prl
│   ├── libQt5ThemeSupport.a
│   ├── libQt5ThemeSupport.prl
│   ├── libQt5Widgets.a
│   ├── libQt5Widgets.prl
│   ├── libQt5XcbQpa.a
│   ├── libQt5XcbQpa.prl
│   ├── libQt5XkbCommonSupport.a
│   ├── libQt5XkbCommonSupport.prl
│   ├── libQt5Zlib.prl
│   ├── libqtharfbuzz.a
│   ├── libqtharfbuzz.prl
│   ├── libqtlibpng.a
│   ├── libqtlibpng.prl
│   ├── libqtpcre2.a
│   ├── libqtpcre2.prl
│   ├── libsqlite3.a
│   ├── libXau.a
│   ├── libxcb-ewmh.so -> libxcb-ewmh.so.2.0.0
│   ├── libxcb-ewmh.so.2 -> libxcb-ewmh.so.2.0.0
│   ├── libxcb-ewmh.so.2.0.0
│   ├── libxcb-icccm.so -> libxcb-icccm.so.4.0.0
│   ├── libxcb-icccm.so.4 -> libxcb-icccm.so.4.0.0
│   ├── libxcb-icccm.so.4.0.0
│   ├── libxcb-image.so -> libxcb-image.so.0.0.0
│   ├── libxcb-image.so.0 -> libxcb-image.so.0.0.0
│   ├── libxcb-image.so.0.0.0
│   ├── libxcb-keysyms.so -> libxcb-keysyms.so.1.0.0
│   ├── libxcb-keysyms.so.1 -> libxcb-keysyms.so.1.0.0
│   ├── libxcb-keysyms.so.1.0.0
│   ├── libxcb-randr.so -> libxcb-randr.so.0.1.0
│   ├── libxcb-randr.so.0 -> libxcb-randr.so.0.1.0
│   ├── libxcb-randr.so.0.1.0
│   ├── libxcb-render.so -> libxcb-render.so.0.0.0
│   ├── libxcb-render.so.0 -> libxcb-render.so.0.0.0
│   ├── libxcb-render.so.0.0.0
│   ├── libxcb-render-util.so -> libxcb-render-util.so.0.0.0
│   ├── libxcb-render-util.so.0 -> libxcb-render-util.so.0.0.0
│   ├── libxcb-render-util.so.0.0.0
│   ├── libxcb-shape.so -> libxcb-shape.so.0.0.0
│   ├── libxcb-shape.so.0 -> libxcb-shape.so.0.0.0
│   ├── libxcb-shape.so.0.0.0
│   ├── libxcb-shm.so -> libxcb-shm.so.0.0.0
│   ├── libxcb-shm.so.0 -> libxcb-shm.so.0.0.0
│   ├── libxcb-shm.so.0.0.0
│   ├── libxcb.so -> libxcb.so.1.1.0
│   ├── libxcb.so.1 -> libxcb.so.1.1.0
│   ├── libxcb.so.1.1.0
│   ├── libxcb-sync.so -> libxcb-sync.so.1.0.0
│   ├── libxcb-sync.so.1 -> libxcb-sync.so.1.0.0
│   ├── libxcb-sync.so.1.0.0
│   ├── libxcb-util.a
│   ├── libxcb-xfixes.so -> libxcb-xfixes.so.0.0.0
│   ├── libxcb-xfixes.so.0 -> libxcb-xfixes.so.0.0.0
│   ├── libxcb-xfixes.so.0.0.0
│   ├── libxcb-xinerama.so -> libxcb-xinerama.so.0.0.0
│   ├── libxcb-xinerama.so.0 -> libxcb-xinerama.so.0.0.0
│   ├── libxcb-xinerama.so.0.0.0
│   ├── libxcb-xkb.so -> libxcb-xkb.so.1.0.0
│   ├── libxcb-xkb.so.1 -> libxcb-xkb.so.1.0.0
│   ├── libxcb-xkb.so.1.0.0
│   ├── libxkbcommon.so -> libxkbcommon.so.0.0.0
│   ├── libxkbcommon.so.0 -> libxkbcommon.so.0.0.0
│   ├── libxkbcommon.so.0.0.0
│   ├── libxkbcommon-x11.so -> libxkbcommon-x11.so.0.0.0
│   ├── libxkbcommon-x11.so.0 -> libxkbcommon-x11.so.0.0.0
│   ├── libxkbcommon-x11.so.0.0.0
│   ├── libzmq.a
│   ├── metatypes
│   ├── pkgconfig
│   ├── python3.11
│   └── Qt5Zlib.la
├── native
│   ├── bin
│   └── mkspecs
├── plugins
│   ├── platforminputcontexts
│   ├── platforms
│   └── platformthemes
├── share
│   ├── aclocal
│   ├── config.site
│   ├── fontconfig
│   ├── pkgconfig
│   ├── toolchain.cmake
│   ├── xcb
│   └── xml
└── translations
    ├── assistant_ar.qm
    ├── assistant_bg.qm
    ├── assistant_cs.qm
    ├── assistant_da.qm
    ├── assistant_de.qm
    ├── assistant_en.qm
    ├── assistant_es.qm
    ├── assistant_fr.qm
    ├── assistant_hr.qm
    ├── assistant_hu.qm
    ├── assistant_ja.qm
    ├── assistant_ko.qm
    ├── assistant_nl.qm
    ├── assistant_pl.qm
    ├── assistant_pt_BR.qm
    ├── assistant_ru.qm
    ├── assistant_sk.qm
    ├── assistant_sl.qm
    ├── assistant_tr.qm
    ├── assistant_uk.qm
    ├── assistant_zh_CN.qm
    ├── assistant_zh_TW.qm
    ├── designer_ar.qm
    ├── designer_bg.qm
    ├── designer_cs.qm
    ├── designer_da.qm
    ├── designer_de.qm
    ├── designer_en.qm
    ├── designer_es.qm
    ├── designer_fr.qm
    ├── designer_hr.qm
    ├── designer_hu.qm
    ├── designer_ja.qm
    ├── designer_ko.qm
    ├── designer_nl.qm
    ├── designer_pl.qm
    ├── designer_ru.qm
    ├── designer_sk.qm
    ├── designer_sl.qm
    ├── designer_tr.qm
    ├── designer_uk.qm
    ├── designer_zh_CN.qm
    ├── designer_zh_TW.qm
    ├── linguist_ar.qm
    ├── linguist_bg.qm
    ├── linguist_cs.qm
    ├── linguist_da.qm
    ├── linguist_de.qm
    ├── linguist_en.qm
    ├── linguist_es.qm
    ├── linguist_fr.qm
    ├── linguist_hr.qm
    ├── linguist_hu.qm
    ├── linguist_it.qm
    ├── linguist_ja.qm
    ├── linguist_ko.qm
    ├── linguist_nl.qm
    ├── linguist_pl.qm
    ├── linguist_ru.qm
    ├── linguist_sk.qm
    ├── linguist_sl.qm
    ├── linguist_sv.qm
    ├── linguist_tr.qm
    ├── linguist_uk.qm
    ├── linguist_zh_CN.qm
    ├── linguist_zh_TW.qm
    ├── qt_ar.qm
    ├── qtbase_ar.qm
    ├── qtbase_bg.qm
    ├── qtbase_ca.qm
    ├── qtbase_cs.qm
    ├── qtbase_da.qm
    ├── qtbase_de.qm
    ├── qtbase_en.qm
    ├── qtbase_es.qm
    ├── qtbase_fa.qm
    ├── qtbase_fi.qm
    ├── qtbase_fr.qm
    ├── qtbase_gd.qm
    ├── qtbase_he.qm
    ├── qtbase_hr.qm
    ├── qtbase_hu.qm
    ├── qtbase_it.qm
    ├── qtbase_ja.qm
    ├── qtbase_ko.qm
    ├── qtbase_lv.qm
    ├── qtbase_nl.qm
    ├── qtbase_nn.qm
    ├── qtbase_pl.qm
    ├── qtbase_pt_BR.qm
    ├── qtbase_ru.qm
    ├── qtbase_sk.qm
    ├── qtbase_tr.qm
    ├── qtbase_uk.qm
    ├── qtbase_zh_CN.qm
    ├── qtbase_zh_TW.qm
    ├── qt_bg.qm
    ├── qt_ca.qm
    ├── qtconnectivity_bg.qm
    ├── qtconnectivity_ca.qm
    ├── qtconnectivity_da.qm
    ├── qtconnectivity_de.qm
    ├── qtconnectivity_en.qm
    ├── qtconnectivity_es.qm
    ├── qtconnectivity_hr.qm
    ├── qtconnectivity_hu.qm
    ├── qtconnectivity_ko.qm
    ├── qtconnectivity_nl.qm
    ├── qtconnectivity_pl.qm
    ├── qtconnectivity_pt_BR.qm
    ├── qtconnectivity_ru.qm
    ├── qtconnectivity_tr.qm
    ├── qtconnectivity_uk.qm
    ├── qtconnectivity_zh_CN.qm
    ├── qt_cs.qm
    ├── qt_da.qm
    ├── qtdeclarative_bg.qm
    ├── qtdeclarative_da.qm
    ├── qtdeclarative_de.qm
    ├── qtdeclarative_en.qm
    ├── qtdeclarative_es.qm
    ├── qtdeclarative_fa.qm
    ├── qtdeclarative_fi.qm
    ├── qtdeclarative_fr.qm
    ├── qtdeclarative_hr.qm
    ├── qtdeclarative_hu.qm
    ├── qtdeclarative_ja.qm
    ├── qtdeclarative_ko.qm
    ├── qtdeclarative_lv.qm
    ├── qtdeclarative_nl.qm
    ├── qtdeclarative_pl.qm
    ├── qtdeclarative_pt_BR.qm
    ├── qtdeclarative_ru.qm
    ├── qtdeclarative_sk.qm
    ├── qtdeclarative_tr.qm
    ├── qtdeclarative_uk.qm
    ├── qtdeclarative_zh_CN.qm
    ├── qt_de.qm
    ├── qt_en.qm
    ├── qt_es.qm
    ├── qt_fa.qm
    ├── qt_fi.qm
    ├── qt_fr.qm
    ├── qt_gd.qm
    ├── qt_gl.qm
    ├── qt_help_ar.qm
    ├── qt_help_bg.qm
    ├── qt_help_ca.qm
    ├── qt_help_cs.qm
    ├── qt_help_da.qm
    ├── qt_help_de.qm
    ├── qt_help_en.qm
    ├── qt_help_es.qm
    ├── qt_help_fr.qm
    ├── qt_help_gl.qm
    ├── qt_help_hr.qm
    ├── qt_help_hu.qm
    ├── qt_help_it.qm
    ├── qt_help_ja.qm
    ├── qt_help_ko.qm
    ├── qt_help_nl.qm
    ├── qt_help_nn.qm
    ├── qt_help_pl.qm
    ├── qt_help_pt_BR.qm
    ├── qt_help_ru.qm
    ├── qt_help_sk.qm
    ├── qt_help_sl.qm
    ├── qt_help_tr.qm
    ├── qt_help_uk.qm
    ├── qt_help_zh_CN.qm
    ├── qt_help_zh_TW.qm
    ├── qt_he.qm
    ├── qt_hr.qm
    ├── qt_hu.qm
    ├── qt_it.qm
    ├── qt_ja.qm
    ├── qt_ko.qm
    ├── qtlocation_bg.qm
    ├── qtlocation_ca.qm
    ├── qtlocation_da.qm
    ├── qtlocation_de.qm
    ├── qtlocation_en.qm
    ├── qtlocation_es.qm
    ├── qtlocation_fi.qm
    ├── qtlocation_fr.qm
    ├── qtlocation_hr.qm
    ├── qtlocation_hu.qm
    ├── qtlocation_ko.qm
    ├── qtlocation_nl.qm
    ├── qtlocation_pl.qm
    ├── qtlocation_pt_BR.qm
    ├── qtlocation_ru.qm
    ├── qtlocation_tr.qm
    ├── qtlocation_uk.qm
    ├── qtlocation_zh_CN.qm
    ├── qt_lt.qm
    ├── qt_lv.qm
    ├── qtmultimedia_ar.qm
    ├── qtmultimedia_bg.qm
    ├── qtmultimedia_ca.qm
    ├── qtmultimedia_cs.qm
    ├── qtmultimedia_da.qm
    ├── qtmultimedia_de.qm
    ├── qtmultimedia_en.qm
    ├── qtmultimedia_es.qm
    ├── qtmultimedia_fa.qm
    ├── qtmultimedia_fi.qm
    ├── qtmultimedia_fr.qm
    ├── qtmultimedia_hr.qm
    ├── qtmultimedia_hu.qm
    ├── qtmultimedia_it.qm
    ├── qtmultimedia_ja.qm
    ├── qtmultimedia_ko.qm
    ├── qtmultimedia_nl.qm
    ├── qtmultimedia_nn.qm
    ├── qtmultimedia_pl.qm
    ├── qtmultimedia_pt_BR.qm
    ├── qtmultimedia_ru.qm
    ├── qtmultimedia_sk.qm
    ├── qtmultimedia_tr.qm
    ├── qtmultimedia_uk.qm
    ├── qtmultimedia_zh_CN.qm
    ├── qtmultimedia_zh_TW.qm
    ├── qt_nl.qm
    ├── qt_nn.qm
    ├── qt_pl.qm
    ├── qt_pt_BR.qm
    ├── qt_pt_PT.qm
    ├── qtquickcontrols2_ar.qm
    ├── qtquickcontrols2_bg.qm
    ├── qtquickcontrols2_ca.qm
    ├── qtquickcontrols2_da.qm
    ├── qtquickcontrols2_en.qm
    ├── qtquickcontrols2_hr.qm
    ├── qtquickcontrols2_hu.qm
    ├── qtquickcontrols2_ko.qm
    ├── qtquickcontrols2_nl.qm
    ├── qtquickcontrols2_nn.qm
    ├── qtquickcontrols2_pt_BR.qm
    ├── qtquickcontrols2_tr.qm
    ├── qtquickcontrols2_uk.qm
    ├── qtquickcontrols2_zh_CN.qm
    ├── qtquickcontrols2_zh_TW.qm
    ├── qtquickcontrols_bg.qm
    ├── qtquickcontrols_ca.qm
    ├── qtquickcontrols_da.qm
    ├── qtquickcontrols_de.qm
    ├── qtquickcontrols_en.qm
    ├── qtquickcontrols_fi.qm
    ├── qtquickcontrols_fr.qm
    ├── qtquickcontrols_hr.qm
    ├── qtquickcontrols_ja.qm
    ├── qtquickcontrols_ko.qm
    ├── qtquickcontrols_nl.qm
    ├── qtquickcontrols_nn.qm
    ├── qtquickcontrols_pt_BR.qm
    ├── qtquickcontrols_ru.qm
    ├── qtquickcontrols_tr.qm
    ├── qtquickcontrols_uk.qm
    ├── qtquickcontrols_zh_CN.qm
    ├── qtquickcontrols_zh_TW.qm
    ├── qt_ru.qm
    ├── qtscript_ar.qm
    ├── qtscript_bg.qm
    ├── qtscript_ca.qm
    ├── qtscript_cs.qm
    ├── qtscript_da.qm
    ├── qtscript_de.qm
    ├── qtscript_en.qm
    ├── qtscript_es.qm
    ├── qtscript_fa.qm
    ├── qtscript_fi.qm
    ├── qtscript_fr.qm
    ├── qtscript_he.qm
    ├── qtscript_hr.qm
    ├── qtscript_hu.qm
    ├── qtscript_it.qm
    ├── qtscript_ja.qm
    ├── qtscript_ko.qm
    ├── qtscript_lv.qm
    ├── qtscript_nl.qm
    ├── qtscript_nn.qm
    ├── qtscript_pl.qm
    ├── qtscript_pt_BR.qm
    ├── qtscript_ru.qm
    ├── qtscript_sk.qm
    ├── qtscript_tr.qm
    ├── qtscript_uk.qm
    ├── qtscript_zh_CN.qm
    ├── qtserialport_de.qm
    ├── qtserialport_en.qm
    ├── qtserialport_es.qm
    ├── qtserialport_ja.qm
    ├── qtserialport_ko.qm
    ├── qtserialport_pl.qm
    ├── qtserialport_ru.qm
    ├── qtserialport_uk.qm
    ├── qt_sk.qm
    ├── qt_sl.qm
    ├── qt_sv.qm
    ├── qt_tr.qm
    ├── qt_uk.qm
    ├── qtwebengine_ca.qm
    ├── qtwebengine_de.qm
    ├── qtwebengine_en.qm
    ├── qtwebengine_es.qm
    ├── qtwebengine_ko.qm
    ├── qtwebengine_pl.qm
    ├── qtwebengine_ru.qm
    ├── qtwebengine_uk.qm
    ├── qtwebsockets_ca.qm
    ├── qtwebsockets_de.qm
    ├── qtwebsockets_en.qm
    ├── qtwebsockets_es.qm
    ├── qtwebsockets_fr.qm
    ├── qtwebsockets_ja.qm
    ├── qtwebsockets_ko.qm
    ├── qtwebsockets_pl.qm
    ├── qtwebsockets_ru.qm
    ├── qtwebsockets_uk.qm
    ├── qtxmlpatterns_bg.qm
    ├── qtxmlpatterns_ca.qm
    ├── qtxmlpatterns_cs.qm
    ├── qtxmlpatterns_da.qm
    ├── qtxmlpatterns_de.qm
    ├── qtxmlpatterns_en.qm
    ├── qtxmlpatterns_es.qm
    ├── qtxmlpatterns_fa.qm
    ├── qtxmlpatterns_fr.qm
    ├── qtxmlpatterns_hr.qm
    ├── qtxmlpatterns_hu.qm
    ├── qtxmlpatterns_it.qm
    ├── qtxmlpatterns_ja.qm
    ├── qtxmlpatterns_ko.qm
    ├── qtxmlpatterns_nl.qm
    ├── qtxmlpatterns_nn.qm
    ├── qtxmlpatterns_pl.qm
    ├── qtxmlpatterns_pt_BR.qm
    ├── qtxmlpatterns_ru.qm
    ├── qtxmlpatterns_sk.qm
    ├── qtxmlpatterns_uk.qm
    ├── qtxmlpatterns_zh_CN.qm
    ├── qtxmlpatterns_zh_TW.qm
    ├── qt_zh_CN.qm
    └── qt_zh_TW.qm

53 directories, 482 files

Cmake only finds boost with -DBOOST_INCLUDEDIR=depends/x86_64-pc-linux-gnu/include/ so I was wondering if libevent needs something similar or if there's a more general way to tell cmake where to look for the depends dir.

0xB10C avatar Mar 20 '24 22:03 0xB10C

CMake tries to find the libevent package by pointing the pkg-config at depends/x86_64-pc-linux-gnu/lib/pkgconfig/libevent.pc (the current Autotools-based system does the same).

That is achieved by setting the PKG_CONFIG_PATH environment variable to /absolute_path_to/depends/x86_64-pc-linux-gnu/lib/pkgconfig.

It can be verified manually like that:

$ env PKG_CONFIG_PATH=/home/hebasto/git/bitcoin/depends/x86_64-pc-linux-gnu/lib/pkgconfig pkg-config --libs libevent
-L/home/hebasto/git/bitcoin/depends/x86_64-pc-linux-gnu/lib -levent

(not sure if it's possible in Nix build environment though)

hebasto avatar Mar 21 '24 10:03 hebasto

Thanks @hebasto! The pointer with PKG_CONFIG_PATH was helpful. PKG_CONFIG_PATH is set in toolchain.cmake (the autotools equivalent to config.site). Previously, I was setting the CONFIG_SITE env variable. Now, I need to set the CMAKE_TOOLCHAIN_FILE env variable (in my case to depends/x86_64-pc-linux-gnu/share/toolchain.cmake).

The documentation on this in https://github.com/hebasto/bitcoin/blob/master/depends/README.md#usage need to be updated as part of the cmake-migration. I'm sure you're aware, I just wasn't :).

Configuring works now, however as of https://github.com/0xB10C/bitcoind-gunix/commit/64b6de699ebdb7f93d4552f5bc8d63815f259e4c:

  1. sqlite wallet dependencies aren't found
  2. GUI dependencies aren't found
  3. NAT-PMP dependencies aren't found
  4. UPnP dependencies aren't found
  5. USDT dependencies aren't found

I'll look into this.

Configure summary
=================
Executables:
  bitcoind ............................ ON
  bitcoin-cli ......................... ON
  bitcoin-tx .......................... ON
  bitcoin-util ........................ ON
  bitcoin-wallet ...................... ON
Wallet support:
  SQLite, descriptor wallets .......... OFF
  Berkeley DB, legacy wallets ......... ON
Optional packages:
  GUI ................................. OFF
  external signer ..................... ON
  NAT-PMP ............................. OFF
  UPnP ................................ OFF
  ZeroMQ .............................. ON
  USDT tracing ........................ OFF
Tests:
  test_bitcoin ........................ OFF
  test_bitcoin-qt ..................... OFF
  bench_bitcoin ....................... OFF
  fuzz binary ......................... OFF

Cross compiling ....................... TRUE, for Linux, x86_64
Preprocessor defined macros ...........
C compiler ............................ /nix/store/km2phngnvjywx3853lfh2bqwyyfz703p-gcc-wrapper-10.5.0/bin/gcc
CFLAGS ................................
C++ compiler .......................... /nix/store/km2phngnvjywx3853lfh2bqwyyfz703p-gcc-wrapper-10.5.0/bin/g++
CXXFLAGS ..............................
Common compile options ................ -fno-extended-identifiers -fstack-reuse=none -Wstack-protector -fstack-protector-all -fcf-protection=full -fstack-clash-protection -Wall -Wextra -Wformat -Wformat-security -Wvla -Wredundant-decls -Wdate-time -Wduplicated-branches -Wduplicated-cond -Wlogical-op -Woverloaded-virtual -Wsuggest-override -Wimplicit-fallthrough -Wunreachable-code -Wno-unused-parameter
Common link options ................... -fno-extended-identifiers -fstack-reuse=none -fstack-protector-all -fcf-protection=full -fstack-clash-protection -Wl,-z,relro -Wl,-z,now -Wl,-z,separate-code
Linker flags for executables ..........
Linker flags for shared libraries .....
Build type (configuration):
 - CMAKE_BUILD_TYPE ................... Release
 - Preprocessor defined macros ........
 - CFLAGS ............................. -O2
 - CXXFLAGS ........................... -O2
 - LDFLAGS for executables ............
 - LDFLAGS for shared libraries .......
Attempt to harden executables ......... ON
Treat compiler warnings as errors ..... OFF
Use ccache for compiling .............. OFF

This compiles and produces a bitcoind binary (without gui, wallet, ...) at the moment.

0xB10C avatar Mar 21 '24 13:03 0xB10C

@0xB10C

  1. sqlite wallet dependencies aren't found

Could you please apply the patch as follows:

--- a/cmake/optional.cmake
+++ b/cmake/optional.cmake
@@ -150,7 +150,11 @@ if(ENABLE_WALLET)
       # Use of the `unofficial::` namespace is a vcpkg package manager convention.
       find_package(unofficial-sqlite3 CONFIG)
     else()
+      message("=== FIND SQLITE BEGINS ===")
+      set(CMAKE_FIND_DEBUG_MODE TRUE)
       find_package(SQLite3 3.7.17)
+      set(CMAKE_FIND_DEBUG_MODE FALSE)
+      message("=== FIND SQLITE ENDS ===")
     endif()
     if(TARGET unofficial::sqlite3::sqlite3 OR TARGET SQLite::SQLite3)
       set(WITH_SQLITE ON)

and provide an excerpt from the build log between marks?

hebasto avatar Mar 22 '24 13:03 hebasto

That's a very helpful trick - thanks for showing me.

=== FIND SQLITE BEGINS ===
CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:36 (find_path):
  find_path called with the following settings:

    VAR: SQLite3_INCLUDE_DIR
    NAMES: "sqlite3.h"
    Documentation: Path to a file.
    Framework
      Only Search Frameworks: 0
      Search Frameworks Last: 1
      Search Frameworks First: 0
    AppBundle
      Only Search AppBundle: 0
      Search AppBundle Last: 0
      Search AppBundle First: 0
    CMAKE_FIND_USE_CMAKE_PATH: 1
    CMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH: 0
    CMAKE_FIND_USE_SYSTEM_ENVIRONMENT_PATH: 1
    CMAKE_FIND_USE_CMAKE_SYSTEM_PATH: 1
    CMAKE_FIND_USE_INSTALL_PREFIX: 1

  find_path considered the following locations:

    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/3ck7yhjzm3h5m3984ni6mj6nbq4saya0-pkg-config-wrapper-0.29.2/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/h3ayxf5dk1gdf3s5716fh1ys815qxxag-patchelf-0.15.0/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/km2phngnvjywx3853lfh2bqwyyfz703p-gcc-wrapper-10.5.0/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/1a9b0d0xyl620mcy8wgh2l42nmarlqbb-gcc-10.5.0/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/vksrk76p5cfbjxb0n95vdkxy7fl2cbcm-glibc-2.38-27-bin/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/m38gwq0w8w7qyjn9s00balyp7cv3m5p9-coreutils-9.3/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/kxgw6wbakp4041y4005iyl9bdi0ri7py-binutils-wrapper-2.40/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/idiaraknw071d20nlqp49s18gbvw4wa0-binutils-2.40/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qwcm1l919ay3kdj41vn3g6df1spd0v2w-hexdump-util-linux-2.39.2/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/a46vw4yj5avynw7i24h3j7iski7y4f6b-which-2.21/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/01znf87kiw5xx1dj0f7djrnrbg84ij28-findutils-4.9.0/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/vq4vmndw555m7ld2bi6pq8kr348qvb6a-diffutils-3.10/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/rwa7qyds01qzxvq7zq3kgnkrzzpw4s66-gnused-4.9/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/n062zcsmfl9gfp6vfkcg0asb8jjwmy5i-gnugrep-3.11/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/4v7m4yx07b3anmbznfhihjc8xiizyna9-gawk-5.2.2/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mi3pm67ps7c7k11aqki9182ygzg8j503-gnutar-1.35/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/5c0ancqnpi0cf1h49mv13w68a950s9z0-gzip-1.13/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/q5cv7r1sh3s4niyq7vm6h1j74394naxs-bzip2-1.0.8-bin/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/bh7sbl99ygfvw9w96936nrhw46jmcmqq-gnumake-4.4.1/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/7dpxg7ki7g8ynkdwcqf493p2x8divb4i-bash-5.2-p15/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mbh9gx43gsc5av019vsdkazbyiic3f0f-patch-2.7.6/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/3q6fnwcm677l1q60vkhcf9m1gxhv83jm-xz-5.4.4-bin/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/a5s2dmba16pw8l52f496gw0b7nli7mbn-file-5.45/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/include/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mmi4l25pxrz3g2330r5vx17y3gnc9497-bitcoind/include/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mmi4l25pxrz3g2330r5vx17y3gnc9497-bitcoind/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/7yidkgqrcw7hg0n0qik1wwa0hycvwjb9-glibc-2.38-27-dev/include/sqlite3.h

  The item was not found.

Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/3ck7yhjzm3h5m3984ni6mj6nbq4saya0-pkg-config-wrapper-0.29.2/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/h3ayxf5dk1gdf3s5716fh1ys815qxxag-patchelf-0.15.0/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/km2phngnvjywx3853lfh2bqwyyfz703p-gcc-wrapper-10.5.0/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/1a9b0d0xyl620mcy8wgh2l42nmarlqbb-gcc-10.5.0/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/vksrk76p5cfbjxb0n95vdkxy7fl2cbcm-glibc-2.38-27-bin/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/m38gwq0w8w7qyjn9s00balyp7cv3m5p9-coreutils-9.3/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/kxgw6wbakp4041y4005iyl9bdi0ri7py-binutils-wrapper-2.40/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/idiaraknw071d20nlqp49s18gbvw4wa0-binutils-2.40/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qwcm1l919ay3kdj41vn3g6df1spd0v2w-hexdump-util-linux-2.39.2/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/a46vw4yj5avynw7i24h3j7iski7y4f6b-which-2.21/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/01znf87kiw5xx1dj0f7djrnrbg84ij28-findutils-4.9.0/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/vq4vmndw555m7ld2bi6pq8kr348qvb6a-diffutils-3.10/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/rwa7qyds01qzxvq7zq3kgnkrzzpw4s66-gnused-4.9/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/n062zcsmfl9gfp6vfkcg0asb8jjwmy5i-gnugrep-3.11/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/4v7m4yx07b3anmbznfhihjc8xiizyna9-gawk-5.2.2/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mi3pm67ps7c7k11aqki9182ygzg8j503-gnutar-1.35/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/5c0ancqnpi0cf1h49mv13w68a950s9z0-gzip-1.13/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/q5cv7r1sh3s4niyq7vm6h1j74394naxs-bzip2-1.0.8-bin/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/bh7sbl99ygfvw9w96936nrhw46jmcmqq-gnumake-4.4.1/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/7dpxg7ki7g8ynkdwcqf493p2x8divb4i-bash-5.2-p15/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mbh9gx43gsc5av019vsdkazbyiic3f0f-patch-2.7.6/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/3q6fnwcm677l1q60vkhcf9m1gxhv83jm-xz-5.4.4-bin/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/a5s2dmba16pw8l52f496gw0b7nli7mbn-file-5.45/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/lib/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mmi4l25pxrz3g2330r5vx17y3gnc9497-bitcoind/lib/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mmi4l25pxrz3g2330r5vx17y3gnc9497-bitcoind/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/j6mwswpa6zqhdm1lm2lv9iix3arn774g-glibc-2.38-27/lib/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library called with the following settings:

    VAR: SQLite3_LIBRARY
    NAMES: "sqlite3"
           "sqlite"
    Documentation: Path to a library.
    Framework
      Only Search Frameworks: 0
      Search Frameworks Last: 1
      Search Frameworks First: 0
    AppBundle
      Only Search AppBundle: 0
      Search AppBundle Last: 0
      Search AppBundle First: 0
    CMAKE_FIND_USE_CMAKE_PATH: 1
    CMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH: 0
    CMAKE_FIND_USE_SYSTEM_ENVIRONMENT_PATH: 1
    CMAKE_FIND_USE_CMAKE_SYSTEM_PATH: 1
    CMAKE_FIND_USE_INSTALL_PREFIX: 1

  find_library considered the following locations:

  The item was not found.

Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


-- Could NOT find SQLite3 (missing: SQLite3_INCLUDE_DIR SQLite3_LIBRARY) (Required is at least version "3.7.17")
CMake Debug Log at cmake/optional.cmake:155 (find_package):
  find_package considered the following paths for FindSQLite3.cmake:

    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/cmake/module/FindSQLite3.cmake

  The file was found at

    /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake

  The module is considered not found due to SQLite3_FOUND being FALSE.
Call Stack (most recent call first):
  CMakeLists.txt:374 (include)


=== FIND SQLITE ENDS ===

The find_path locations it considers for sqlite are weird. For example, it finds bdb in /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/lib/libdb_cxx-4.8.a which is where I'd assume it would be.

-- Found BerkeleyDB: /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/lib/libdb_cxx-4.8.a (found suitable version "4.8.30", minimum required is "4.8")

0xB10C avatar Mar 22 '24 13:03 0xB10C

Could you please try to configure CMake with -DCMAKE_FIND_USE_INSTALL_PREFIX=OFF?

hebasto avatar Mar 22 '24 13:03 hebasto

That doesn't seem to help:

=== FIND SQLITE BEGINS ===
CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:36 (find_path):
  find_path called with the following settings:

    VAR: SQLite3_INCLUDE_DIR
    NAMES: "sqlite3.h"
    Documentation: Path to a file.
    Framework
      Only Search Frameworks: 0
      Search Frameworks Last: 1
      Search Frameworks First: 0
    AppBundle
      Only Search AppBundle: 0
      Search AppBundle Last: 0
      Search AppBundle First: 0
    CMAKE_FIND_USE_CMAKE_PATH: 1
    CMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH: 0
    CMAKE_FIND_USE_SYSTEM_ENVIRONMENT_PATH: 1
    CMAKE_FIND_USE_CMAKE_SYSTEM_PATH: 1
    CMAKE_FIND_USE_INSTALL_PREFIX: 0

  find_path considered the following locations:

    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/3ck7yhjzm3h5m3984ni6mj6nbq4saya0-pkg-config-wrapper-0.29.2/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/h3ayxf5dk1gdf3s5716fh1ys815qxxag-patchelf-0.15.0/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/km2phngnvjywx3853lfh2bqwyyfz703p-gcc-wrapper-10.5.0/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/1a9b0d0xyl620mcy8wgh2l42nmarlqbb-gcc-10.5.0/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/vksrk76p5cfbjxb0n95vdkxy7fl2cbcm-glibc-2.38-27-bin/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/m38gwq0w8w7qyjn9s00balyp7cv3m5p9-coreutils-9.3/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/kxgw6wbakp4041y4005iyl9bdi0ri7py-binutils-wrapper-2.40/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/idiaraknw071d20nlqp49s18gbvw4wa0-binutils-2.40/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qwcm1l919ay3kdj41vn3g6df1spd0v2w-hexdump-util-linux-2.39.2/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/a46vw4yj5avynw7i24h3j7iski7y4f6b-which-2.21/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/01znf87kiw5xx1dj0f7djrnrbg84ij28-findutils-4.9.0/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/vq4vmndw555m7ld2bi6pq8kr348qvb6a-diffutils-3.10/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/rwa7qyds01qzxvq7zq3kgnkrzzpw4s66-gnused-4.9/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/n062zcsmfl9gfp6vfkcg0asb8jjwmy5i-gnugrep-3.11/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/4v7m4yx07b3anmbznfhihjc8xiizyna9-gawk-5.2.2/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mi3pm67ps7c7k11aqki9182ygzg8j503-gnutar-1.35/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/5c0ancqnpi0cf1h49mv13w68a950s9z0-gzip-1.13/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/q5cv7r1sh3s4niyq7vm6h1j74394naxs-bzip2-1.0.8-bin/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/bh7sbl99ygfvw9w96936nrhw46jmcmqq-gnumake-4.4.1/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/7dpxg7ki7g8ynkdwcqf493p2x8divb4i-bash-5.2-p15/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mbh9gx43gsc5av019vsdkazbyiic3f0f-patch-2.7.6/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/3q6fnwcm677l1q60vkhcf9m1gxhv83jm-xz-5.4.4-bin/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/a5s2dmba16pw8l52f496gw0b7nli7mbn-file-5.45/bin/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/include/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/sqlite3.h
    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/7yidkgqrcw7hg0n0qik1wwa0hycvwjb9-glibc-2.38-27-dev/include/sqlite3.h

  The item was not found.

Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/3ck7yhjzm3h5m3984ni6mj6nbq4saya0-pkg-config-wrapper-0.29.2/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/h3ayxf5dk1gdf3s5716fh1ys815qxxag-patchelf-0.15.0/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/km2phngnvjywx3853lfh2bqwyyfz703p-gcc-wrapper-10.5.0/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/1a9b0d0xyl620mcy8wgh2l42nmarlqbb-gcc-10.5.0/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/vksrk76p5cfbjxb0n95vdkxy7fl2cbcm-glibc-2.38-27-bin/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/m38gwq0w8w7qyjn9s00balyp7cv3m5p9-coreutils-9.3/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/kxgw6wbakp4041y4005iyl9bdi0ri7py-binutils-wrapper-2.40/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/idiaraknw071d20nlqp49s18gbvw4wa0-binutils-2.40/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qwcm1l919ay3kdj41vn3g6df1spd0v2w-hexdump-util-linux-2.39.2/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/a46vw4yj5avynw7i24h3j7iski7y4f6b-which-2.21/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/01znf87kiw5xx1dj0f7djrnrbg84ij28-findutils-4.9.0/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/vq4vmndw555m7ld2bi6pq8kr348qvb6a-diffutils-3.10/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/rwa7qyds01qzxvq7zq3kgnkrzzpw4s66-gnused-4.9/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/n062zcsmfl9gfp6vfkcg0asb8jjwmy5i-gnugrep-3.11/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/4v7m4yx07b3anmbznfhihjc8xiizyna9-gawk-5.2.2/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mi3pm67ps7c7k11aqki9182ygzg8j503-gnutar-1.35/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/5c0ancqnpi0cf1h49mv13w68a950s9z0-gzip-1.13/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/q5cv7r1sh3s4niyq7vm6h1j74394naxs-bzip2-1.0.8-bin/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/bh7sbl99ygfvw9w96936nrhw46jmcmqq-gnumake-4.4.1/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/7dpxg7ki7g8ynkdwcqf493p2x8divb4i-bash-5.2-p15/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/mbh9gx43gsc5av019vsdkazbyiic3f0f-patch-2.7.6/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/3q6fnwcm677l1q60vkhcf9m1gxhv83jm-xz-5.4.4-bin/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/a5s2dmba16pw8l52f496gw0b7nli7mbn-file-5.45/bin/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/lib/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library(SQLite3_LIBRARY) removed original suffix
  /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/j6mwswpa6zqhdm1lm2lv9iix3arn774g-glibc-2.38-27/lib/
  from PATH_SUFFIXES while adding architecture paths for suffix '64'
Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


CMake Debug Log at /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake:40 (find_library):
  find_library called with the following settings:

    VAR: SQLite3_LIBRARY
    NAMES: "sqlite3"
           "sqlite"
    Documentation: Path to a library.
    Framework
      Only Search Frameworks: 0
      Search Frameworks Last: 1
      Search Frameworks First: 0
    AppBundle
      Only Search AppBundle: 0
      Search AppBundle Last: 0
      Search AppBundle First: 0
    CMAKE_FIND_USE_CMAKE_PATH: 1
    CMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH: 0
    CMAKE_FIND_USE_SYSTEM_ENVIRONMENT_PATH: 1
    CMAKE_FIND_USE_CMAKE_SYSTEM_PATH: 1
    CMAKE_FIND_USE_INSTALL_PREFIX: 0

  find_library considered the following locations:

  The item was not found.

Call Stack (most recent call first):
  cmake/optional.cmake:155 (find_package)
  CMakeLists.txt:374 (include)


-- Could NOT find SQLite3 (missing: SQLite3_INCLUDE_DIR SQLite3_LIBRARY) (Required is at least version "3.7.17")
CMake Debug Log at cmake/optional.cmake:155 (find_package):
  find_package considered the following paths for FindSQLite3.cmake:

    /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/cmake/module/FindSQLite3.cmake

  The file was found at

    /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/share/cmake-3.27/Modules/FindSQLite3.cmake

  The module is considered not found due to SQLite3_FOUND being FALSE.
Call Stack (most recent call first):
  CMakeLists.txt:374 (include)


=== FIND SQLITE ENDS ===
-- Found BerkeleyDB: /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/lib/libdb_cxx-4.8.a (found suitable version "4.8.30", minimum required is "4.8")

0xB10C avatar Mar 22 '24 14:03 0xB10C

However, I can set -DSQLite3_INCLUDE_DIR=/absolute/path/to/depends/include/ -DSQLite3_LIBRARY=/absolute/path/to/depends/lib/ and it finds and builds with sqlite. Though, that's a hack and defeats the purpose of having cmake in the first place.

0xB10C avatar Mar 22 '24 14:03 0xB10C

Just in case, what are values of all CMAKE_* environment variables?

hebasto avatar Mar 22 '24 14:03 hebasto

To be clear, cmake looks for sqlite.h in e.g. /build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/include/sqlite3.h

/build/bitcoin-5e65a38896525cdb84f25e0968cc230e147cfc9b/depends/x86_64-pc-linux-gnu is the correct absolute depends path. /nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7/ is the Nix path to the cmake installation. Similarly, it's also looking in the gnutar, gzip, ... installation directories. This seems wrong.

0xB10C avatar Mar 22 '24 14:03 0xB10C

Just in case, what are values of all CMAKE_* environment variables?

Besides CMAKE_TOOLCHAIN_FILE, which I set, there's

CMAKE_PREFIX_PATH="/nix/store/3ck7yhjzm3h5m3984ni6mj6nbq4saya0-pkg-config-wrapper-0.29.2:/nix/store/h3ayxf5dk1gdf3s5716fh1ys815qxxag-patchelf-0.15.0:/nix/store/v5qyd49a256y44pz75qnsp9741mg336k-update-autotools-gnu-config-scripts-hook:/nix/store/km2phngnvjywx3853lfh2bqwyyfz703p-gcc-wrapper-10.5.0:/nix/store/kxgw6wbakp4041y4005iyl9bdi0ri7py-binutils-wrapper-2.40:/nix/store/qacx56cg97hmwgh3gqz9a7qgdw82zmdp-cmake-3.27.7:/nix/store/qwcm1l919ay3kdj41vn3g6df1spd0v2w-hexdump-util-linux-2.39.2:/nix/store/a46vw4yj5avynw7i24h3j7iski7y4f6b-which-2.21"

This looks very much like the problem!

0xB10C avatar Mar 22 '24 14:03 0xB10C

Setting CMAKE_PREFIX_PATH seems to be a nixos thing: https://nixos.org/manual/nixpkgs/stable/#cmake

0xB10C avatar Mar 22 '24 14:03 0xB10C

What about configuring with -DCMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH=OFF?

hebasto avatar Mar 22 '24 14:03 hebasto

What about configuring with -DCMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH=OFF?

Similar to https://github.com/hebasto/bitcoin/issues/121#issuecomment-2015185149 - does not find sqlite. I've also tried -DCMAKE_FIND_USE_SYSTEM_ENVIRONMENT_PATH=OFF, but that does not seem to work at all.

0xB10C avatar Mar 22 '24 14:03 0xB10C

What about configuring with -DCMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH=OFF?

Similar to #121 (comment) - does not find sqlite. I've also tried -DCMAKE_FIND_USE_SYSTEM_ENVIRONMENT_PATH=OFF, but that does not seem to work at all.

Ah, I've just noticed CMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH: 0 in https://github.com/hebasto/bitcoin/issues/121#issuecomment-2015185149.

Sorry for false guessing :)

Another option to try is -DCMAKE_FIND_USE_CMAKE_PATH=OFF.

hebasto avatar Mar 22 '24 14:03 hebasto

What about configuring with -DCMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH=OFF?

Similar to #121 (comment) - does not find sqlite. I've also tried -DCMAKE_FIND_USE_SYSTEM_ENVIRONMENT_PATH=OFF, but that does not seem to work at all.

Ah, I've just noticed CMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH: 0 in #121 (comment).

Sorry for false guessing :)

Another option to try is -DCMAKE_FIND_USE_CMAKE_PATH=OFF.

Did not work, but -DCMAKE_PREFIX_PATH=/ does!!

Configure summary
=================
Executables:
  bitcoind ............................ ON
  bitcoin-cli ......................... ON
  bitcoin-tx .......................... ON
  bitcoin-util ........................ ON
  bitcoin-wallet ...................... ON
Wallet support:
  SQLite, descriptor wallets .......... ON
  Berkeley DB, legacy wallets ......... ON
Optional packages:
  GUI ................................. Qt5
  QR code (GUI) ....................... ON
  external signer ..................... ON
  NAT-PMP ............................. ON
  UPnP ................................ ON
  ZeroMQ .............................. ON
  USDT tracing ........................ ON
Tests:
  test_bitcoin ........................ OFF
  test_bitcoin-qt ..................... OFF
  bench_bitcoin ....................... OFF
  fuzz binary ......................... OFF

Cross compiling ....................... TRUE, for Linux, x86_64
Preprocessor defined macros ...........
C compiler ............................ /nix/store/km2phngnvjywx3853lfh2bqwyyfz703p-gcc-wrapper-10.5.0/bin/gcc
CFLAGS ................................
C++ compiler .......................... /nix/store/km2phngnvjywx3853lfh2bqwyyfz703p-gcc-wrapper-10.5.0/bin/g++
CXXFLAGS ..............................
Common compile options ................ -fno-extended-identifiers -fstack-reuse=none -Wstack-protector -fstack-protector-all -fcf-protection=full -fstack-clash-protection -Wall -Wextra -Wformat -Wformat-security -Wvla -Wredundant-decls -Wdate-time -Wduplicated-branches -Wduplicated-cond -Wlogical-op -Woverloaded-virtual -Wsuggest-override -Wimplicit-fallthrough -Wunreachable-code -Wno-unused-parameter
Common link options ................... -fno-extended-identifiers -fstack-reuse=none -fstack-protector-all -fcf-protection=full -fstack-clash-protection -Wl,-z,relro -Wl,-z,now -Wl,-z,separate-code
Linker flags for executables ..........
Linker flags for shared libraries .....
Build type (configuration):
 - CMAKE_BUILD_TYPE ................... Release
 - Preprocessor defined macros ........
 - CFLAGS ............................. -O2
 - CXXFLAGS ........................... -O2
 - LDFLAGS for executables ............
 - LDFLAGS for shared libraries .......
Attempt to harden executables ......... ON
Treat compiler warnings as errors ..... OFF
Use ccache for compiling .............. OFF

Thank you! I'll report back if I run into any other issues.

0xB10C avatar Mar 22 '24 14:03 0xB10C