From bed5feac851949e591b68ff6e6a58e648bc729d9 Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Sun, 12 May 2024 08:57:20 +0100 Subject: [PATCH] cmake: Rename build option `MULTIPROCESS` to `WITH_MULTIPROCESS` --- CMakeLists.txt | 14 ++++++++++---- depends/toolchain.cmake.in | 4 ++-- src/CMakeLists.txt | 4 ++-- src/qt/CMakeLists.txt | 2 +- src/test/CMakeLists.txt | 2 +- 5 files changed, 16 insertions(+), 10 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 0751c71f52d80..3c110ae979bf7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -155,8 +155,8 @@ endif() cmake_dependent_option(WITH_DBUS "Enable DBus support." ON "CMAKE_SYSTEM_NAME STREQUAL \"Linux\" AND BUILD_GUI" OFF) -option(MULTIPROCESS "Build multiprocess bitcoin-node, bitcoin-wallet, and bitcoin-gui executables in addition to monolithic bitcoind and bitcoin-qt executables. Requires libmultiprocess library. Experimental." OFF) -if(MULTIPROCESS) +option(WITH_MULTIPROCESS "Build multiprocess bitcoin-node and bitcoin-gui executables in addition to monolithic bitcoind and bitcoin-qt executables. Requires libmultiprocess library. Experimental." OFF) +if(WITH_MULTIPROCESS) find_package(Libmultiprocess CONFIG REQUIRED) find_package(LibmultiprocessGen CONFIG REQUIRED) endif() @@ -604,7 +604,14 @@ message("Configure summary") message("=================") message("Executables:") message(" bitcoind ............................ ${BUILD_DAEMON}") -message(" bitcoin-qt .......................... ${BUILD_GUI}") +message(" bitcoin-node (multiprocess) ......... ${WITH_MULTIPROCESS}") +message(" bitcoin-qt (GUI) .................... ${BUILD_GUI}") +if(BUILD_GUI AND WITH_MULTIPROCESS) + set(bitcoin_gui_status ON) +else() + set(bitcoin_gui_status OFF) +endif() +message(" bitcoin-gui (GUI, multiprocess) ..... ${bitcoin_gui_status}") message(" bitcoin-cli ......................... ${BUILD_CLI}") message(" bitcoin-tx .......................... ${BUILD_TX}") message(" bitcoin-util ........................ ${BUILD_UTIL}") @@ -616,7 +623,6 @@ message(" SQLite, descriptor wallets .......... ${WITH_SQLITE}") message(" Berkeley DB, legacy wallets ......... ${WITH_BDB}") message("Optional packages:") message(" external signer ..................... ${WITH_EXTERNAL_SIGNER}") -message(" multiprocess ........................ ${MULTIPROCESS}") message(" NAT-PMP ............................. ${WITH_NATPMP}") message(" UPnP ................................ ${WITH_MINIUPNPC}") message(" ZeroMQ .............................. ${WITH_ZMQ}") diff --git a/depends/toolchain.cmake.in b/depends/toolchain.cmake.in index 80c2d6b168a09..354d0966d33b8 100644 --- a/depends/toolchain.cmake.in +++ b/depends/toolchain.cmake.in @@ -185,8 +185,8 @@ else() endif() if("@multiprocess@" STREQUAL "1") - set(MULTIPROCESS ON CACHE BOOL "") + set(WITH_MULTIPROCESS ON CACHE BOOL "") set(LibmultiprocessGen_DIR "${CMAKE_FIND_ROOT_PATH}/native/lib/cmake/LibmultiprocessGen" CACHE PATH "") else() - set(MULTIPROCESS OFF CACHE BOOL "") + set(WITH_MULTIPROCESS OFF CACHE BOOL "") endif() diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index b2152ff02fcf3..62defd47231ba 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -35,7 +35,7 @@ add_dependencies(bitcoin_clientversion generate_build_info) add_subdirectory(crypto) add_subdirectory(univalue) add_subdirectory(util) -if(MULTIPROCESS) +if(WITH_MULTIPROCESS) add_subdirectory(ipc) endif() @@ -277,7 +277,7 @@ if(BUILD_DAEMON) ) list(APPEND installable_targets bitcoind) endif() -if(MULTIPROCESS) +if(WITH_MULTIPROCESS) add_executable(bitcoin-node bitcoind.cpp init/bitcoin-node.cpp diff --git a/src/qt/CMakeLists.txt b/src/qt/CMakeLists.txt index 4996e48037693..2e5006b400631 100644 --- a/src/qt/CMakeLists.txt +++ b/src/qt/CMakeLists.txt @@ -210,7 +210,7 @@ if(WIN32) set_target_properties(bitcoin-qt PROPERTIES WIN32_EXECUTABLE TRUE) endif() -if(MULTIPROCESS) +if(WITH_MULTIPROCESS) add_executable(bitcoin-gui main.cpp ../init/bitcoin-gui.cpp diff --git a/src/test/CMakeLists.txt b/src/test/CMakeLists.txt index dee8969a7d168..27c76e6257bd2 100644 --- a/src/test/CMakeLists.txt +++ b/src/test/CMakeLists.txt @@ -155,7 +155,7 @@ if(ENABLE_WALLET) add_subdirectory(${PROJECT_SOURCE_DIR}/src/wallet/test wallet) endif() -if(MULTIPROCESS) +if(WITH_MULTIPROCESS) add_library(bitcoin_ipc_test STATIC EXCLUDE_FROM_ALL ipc_test.cpp )