aboutsummaryrefslogtreecommitdiff
path: root/src/zmq/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'src/zmq/CMakeLists.txt')
-rw-r--r--src/zmq/CMakeLists.txt24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/zmq/CMakeLists.txt b/src/zmq/CMakeLists.txt
new file mode 100644
index 0000000000..8ecb236b46
--- /dev/null
+++ b/src/zmq/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Copyright (c) 2023-present The Bitcoin Core developers
+# Distributed under the MIT software license, see the accompanying
+# file COPYING or https://opensource.org/license/mit/.
+
+add_library(bitcoin_zmq STATIC EXCLUDE_FROM_ALL
+ zmqabstractnotifier.cpp
+ zmqnotificationinterface.cpp
+ zmqpublishnotifier.cpp
+ zmqrpc.cpp
+ zmqutil.cpp
+)
+target_compile_definitions(bitcoin_zmq
+ INTERFACE
+ ENABLE_ZMQ=1
+ PRIVATE
+ $<$<AND:$<PLATFORM_ID:Windows>,$<CXX_COMPILER_ID:GNU>>:ZMQ_STATIC>
+)
+target_link_libraries(bitcoin_zmq
+ PRIVATE
+ core_interface
+ univalue
+ $<TARGET_NAME_IF_EXISTS:libzmq>
+ $<TARGET_NAME_IF_EXISTS:PkgConfig::libzmq>
+)