forked from bitcoin/bitcoin
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge #173: cmake: Switch from tri-state options to boolean. Stage FI…
…VE. The GUI c46dd16 cmake [KILL 3-STATE]: Rename WITH_GUI to BUILD_GUI (Hennadii Stepanov) d06252f cmake [KILL 3-STATE]: Make WITH_GUI binary option w/ default OFF (Hennadii Stepanov) Pull request description: Replaces multi-value `WITH_GUI` with boolean `BUILD_GUI` as discussed during the recent call. The default value of the `BUILD_GUI` option is `OFF`. Documentation has been adjusted. While touching build docs, they were amended to use modern CMake invocations according to discussion in #167 (should be trivial to review though). Top commit has no ACKs. Tree-SHA512: ebe65f616e2044a6b09e8b1ff3685fd4f8fca6be2f2324db7495b56bbfdb03e6ab7d5a80d1a91ef903e11417590f9267cc2f80aa591379cb193ced36fbebbec0
- Loading branch information
Showing
12 changed files
with
116 additions
and
114 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
# Copyright (c) 2024-present The Bitcoin Core developers | ||
# Distributed under the MIT software license, see the accompanying | ||
# file COPYING or https://opensource.org/license/mit/. | ||
|
||
#[=======================================================================[ | ||
FindQt5 | ||
------- | ||
Finds the Qt 5 headers and libraries. | ||
This is a wrapper around find_package() command that: | ||
- facilitates searching in various build environments | ||
- prints a standard log message | ||
#]=======================================================================] | ||
|
||
set(_qt_homebrew_prefix) | ||
if(CMAKE_HOST_APPLE) | ||
find_program(HOMEBREW_EXECUTABLE brew) | ||
if(HOMEBREW_EXECUTABLE) | ||
execute_process( | ||
COMMAND ${HOMEBREW_EXECUTABLE} --prefix qt@5 | ||
OUTPUT_VARIABLE _qt_homebrew_prefix | ||
ERROR_QUIET | ||
OUTPUT_STRIP_TRAILING_WHITESPACE | ||
) | ||
endif() | ||
endif() | ||
|
||
# Save CMAKE_FIND_ROOT_PATH_MODE_LIBRARY state. | ||
unset(_qt_find_root_path_mode_library_saved) | ||
if(DEFINED CMAKE_FIND_ROOT_PATH_MODE_LIBRARY) | ||
set(_qt_find_root_path_mode_library_saved ${CMAKE_FIND_ROOT_PATH_MODE_LIBRARY}) | ||
endif() | ||
|
||
# The Qt config files internally use find_library() calls for all | ||
# dependencies to ensure their availability. In turn, the find_library() | ||
# inspects the well-known locations on the file system; therefore, it must | ||
# be able to find platform-specific system libraries, for example: | ||
# /usr/x86_64-w64-mingw32/lib/libm.a or /usr/arm-linux-gnueabihf/lib/libm.a. | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH) | ||
|
||
find_package(Qt5 ${Qt5_FIND_VERSION} | ||
COMPONENTS ${Qt5_FIND_COMPONENTS} | ||
HINTS ${_qt_homebrew_prefix} | ||
PATH_SUFFIXES Qt5 # Required on OpenBSD systems. | ||
) | ||
unset(_qt_homebrew_prefix) | ||
|
||
# Restore CMAKE_FIND_ROOT_PATH_MODE_LIBRARY state. | ||
if(DEFINED _qt_find_root_path_mode_library_saved) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ${_qt_find_root_path_mode_library_saved}) | ||
unset(_qt_find_root_path_mode_library_saved) | ||
else() | ||
unset(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY) | ||
endif() | ||
|
||
include(FindPackageHandleStandardArgs) | ||
find_package_handle_standard_args(Qt5 | ||
REQUIRED_VARS Qt5_DIR | ||
VERSION_VAR Qt5_VERSION | ||
) |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -343,7 +343,7 @@ if(BUILD_UTIL) | |
endif() | ||
|
||
|
||
if(WITH_GUI) | ||
if(BUILD_GUI) | ||
add_subdirectory(qt) | ||
endif() | ||
|
||
|
Oops, something went wrong.