forked from bitcoin/bitcoin
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
49 lines (43 loc) · 1.41 KB
/
CMakeLists.txt
File metadata and controls
49 lines (43 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# 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_ipc STATIC EXCLUDE_FROM_ALL
capnp/mining.cpp
capnp/protocol.cpp
interfaces.cpp
process.cpp
)
target_capnp_sources(bitcoin_ipc ${CMAKE_CURRENT_SOURCE_DIR}
capnp/common.capnp
capnp/echo.capnp
capnp/init.capnp
capnp/mining.capnp
)
target_link_libraries(bitcoin_ipc
PRIVATE
core_interface
univalue
Boost::headers
)
if(BUILD_TESTS)
# bitcoin_ipc_test library target is defined here in src/ipc/CMakeLists.txt
# instead of src/ipc/test/CMakeLists.txt so capnp files in src/ipc/test/ are able to
# reference capnp files in src/ipc/capnp/ by relative path. The Cap'n Proto
# compiler only allows importing by relative path when the importing and
# imported files are underneath the same compilation source prefix, so the
# source prefix must be src/ipc, not src/ipc/test/
add_library(bitcoin_ipc_test STATIC EXCLUDE_FROM_ALL
test/ipc_test.cpp
)
target_capnp_sources(bitcoin_ipc_test ${CMAKE_CURRENT_SOURCE_DIR}
test/ipc_test.capnp
)
add_dependencies(bitcoin_ipc_test bitcoin_ipc_headers)
target_link_libraries(bitcoin_ipc_test
PRIVATE
core_interface
univalue
Boost::headers
)
endif()
configure_file(.clang-tidy.in .clang-tidy USE_SOURCE_PERMISSIONS COPYONLY)