simplify: remove conan check for enhanced logging

Since Xahau now exclusively uses Conan for builds, we can remove the
conditional check for conan_toolchain. The enhanced logging feature
now simply defaults to ON for Debug builds and OFF for Release builds.
This commit is contained in:
Nicholas Dudfield
2025-09-08 16:10:57 +07:00
parent 917bcf1008
commit 2c11bfd678

View File

@@ -37,18 +37,12 @@ endif() #git
set(SOURCE_ROOT_PATH "${CMAKE_CURRENT_SOURCE_DIR}/src/")
add_definitions(-DSOURCE_ROOT_PATH="${SOURCE_ROOT_PATH}")
# BEAST_ENHANCED_LOGGING option - only available with Conan builds that have date-tz
# BEAST_ENHANCED_LOGGING option - adds file:line numbers and formatting to logs
# Default to ON for Debug builds, OFF for Release
if(CMAKE_TOOLCHAIN_FILE MATCHES "conan_toolchain")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
option(BEAST_ENHANCED_LOGGING "Include file and line numbers in log messages" ON)
else()
option(BEAST_ENHANCED_LOGGING "Include file and line numbers in log messages" OFF)
endif()
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
option(BEAST_ENHANCED_LOGGING "Include file and line numbers in log messages" ON)
else()
# Non-Conan builds don't have date-tz support
set(BEAST_ENHANCED_LOGGING OFF CACHE BOOL "Enhanced logging requires Conan build" FORCE)
message(STATUS "Enhanced logging disabled - requires Conan build for date-tz support")
option(BEAST_ENHANCED_LOGGING "Include file and line numbers in log messages" OFF)
endif()
if(BEAST_ENHANCED_LOGGING)