build: define CMAKE_COMPILE_WARNING_AS_ERROR as a cache option

CMAKE_COMPILE_WARNING_AS_ERROR is not a cache variable by default in
CMake, so it has no value in the configure summary when not set, and
even when set cannot be toggled in ccmake. Define it as an option() to
make it a cache BOOL with a default of OFF.
This commit is contained in:
will
2026-02-17 12:26:01 +00:00
parent 35e6444fdc
commit 231dd04b8d

View File

@@ -119,6 +119,7 @@ endif()
cmake_dependent_option(BUILD_WALLET_TOOL "Build bitcoin-wallet tool." ${BUILD_TESTS} "ENABLE_WALLET" OFF)
option(REDUCE_EXPORTS "Attempt to reduce exported symbols in the resulting executables." OFF)
option(CMAKE_COMPILE_WARNING_AS_ERROR "Treat compiler warnings as errors." OFF)
option(WITH_CCACHE "Attempt to use ccache for compiling." ON)
option(WITH_ZMQ "Enable ZMQ notifications." OFF)