CMakeLists.txt raw
1 # Copyright (c) The Bitcoin Core developers
2 # Distributed under the MIT software license, see the accompanying
3 # file COPYING or http://www.opensource.org/licenses/mit-license.php.
4
5 include(${PROJECT_SOURCE_DIR}/cmake/TargetCapnpSources.cmake)
6
7 add_executable(mpcalculator
8 calculator.cpp
9 )
10 target_capnp_sources(mpcalculator ${CMAKE_CURRENT_SOURCE_DIR} init.capnp calculator.capnp printer.capnp)
11 target_include_directories(mpcalculator PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
12 target_link_libraries(mpcalculator PRIVATE Threads::Threads)
13
14 add_executable(mpprinter
15 printer.cpp
16 )
17 target_capnp_sources(mpprinter ${CMAKE_CURRENT_SOURCE_DIR} init.capnp calculator.capnp printer.capnp)
18 target_include_directories(mpprinter PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
19 target_link_libraries(mpprinter PRIVATE Threads::Threads)
20
21 add_executable(mpexample
22 example.cpp
23 )
24 target_capnp_sources(mpexample ${CMAKE_CURRENT_SOURCE_DIR} init.capnp calculator.capnp printer.capnp)
25 target_include_directories(mpexample PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
26 target_link_libraries(mpexample PRIVATE Threads::Threads)
27
28 add_custom_target(mpexamples DEPENDS mpexample mpcalculator mpprinter)
29