cculianu / Fulcrum

A fast & nimble SPV Server for BCH, BTC, and LTC
Other
325 stars 73 forks source link

Can't compile Fulcrum against libzmq on macOS #220

Closed cairesantos closed 7 months ago

cairesantos commented 7 months ago

I tried the steps to pass LIBS and INCLUDEPATH along with make, but it didn't work. I check and libs and zmq are installed and available.

Screen Shot 2023-12-23 at 19 46 50 Screen Shot 2023-12-23 at 19 47 12

I actually tried with both paths for LIBS but still...

Trial 1 (on lib root) Nos-MacBook-Pro Fulcrum-1.9.7 % qmake LIBS+="/usr/local/Cellar/zeromq/4.3.5_1/lib" INCLUDEPATH+="/usr/local/Cellar/zeromq/4.3.5_1/include" Project MESSAGE: CLI overrides: LIBS=/usr/local/Cellar/zeromq/4.3.5_1/lib Project MESSAGE: CLI overrides: INCLUDEPATH=/usr/local/Cellar/zeromq/4.3.5_1/include Project MESSAGE: ZMQ not found, install pkg-config and libzmq to enable ZMQ notifications. Project MESSAGE: rocksdb: using static lib Project MESSAGE: jemalloc: not found, will use system allocator Project MESSAGE: Including embedded secp256k1 Project MESSAGE: Installation dir prefix is /usr/local

Trial 2 (on pkgconfig) Nos-MacBook-Pro Fulcrum-1.9.7 % qmake LIBS+="/usr/local/Cellar/zeromq/4.3.5_1/lib/pkgconfig" INCLUDEPATH+="/usr/local/Cellar/zeromq/4.3.5_1/include" Project MESSAGE: CLI overrides: LIBS=/usr/local/Cellar/zeromq/4.3.5_1/lib/pkgconfig Project MESSAGE: CLI overrides: INCLUDEPATH=/usr/local/Cellar/zeromq/4.3.5_1/include Project MESSAGE: ZMQ not found, install pkg-config and libzmq to enable ZMQ notifications. Project MESSAGE: rocksdb: using static lib Project MESSAGE: jemalloc: not found, will use system allocator Project MESSAGE: Including embedded secp256k1 Project MESSAGE: Installation dir prefix is /usr/local

Btw.. I am running on an old MBP late 2012 (Intel x64) running on macOS 11.7.10 (BigSur)

Help is much appreciated.

Regards, Caire.

cairesantos commented 7 months ago

I found the answer in the meantime... If any one runs at the same issue:

I ran qmake with the following attributes:

qmake -o Makefile Fulcrum.pro LIBS+=-L"/usr/local/Cellar/zeromq/4.3.5_1/lib -lzmq" INCLUDEPATH+=/usr/local/Cellar/zeromq/4.3.5_1/include

and this was the output:

Project MESSAGE: CLI overrides: LIBS=-L/usr/local/Cellar/zeromq/4.3.5_1/lib -lzmq Project MESSAGE: CLI overrides: INCLUDEPATH=/usr/local/Cellar/zeromq/4.3.5_1/include Project MESSAGE: ZMQ: using CLI override Project MESSAGE: rocksdb: using static lib Project MESSAGE: jemalloc: not found, will use system allocator Project MESSAGE: Including embedded secp256k1 Project MESSAGE: Installation dir prefix is /usr/local

cculianu commented 7 months ago

Yay! Thanks for solving it! :) Yeah the "LIBS" line is super low-level. You basically just give it a CLI arg for the linker.. :/