Skip to content

Commit

Permalink
Validate that c++20 if SPDLOG_USE_FMT_FORMAT=ON
Browse files Browse the repository at this point in the history
  • Loading branch information
gabime committed Sep 16, 2023
1 parent c1e4c80 commit ca49a12
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,10 @@ if(SPDLOG_USE_STD_FORMAT AND SPDLOG_FMT_EXTERNAL)
message(FATAL_ERROR "SPDLOG_USE_STD_FORMAT and SPDLOG_FMT_EXTERNAL are mutually exclusive")
endif()

if(SPDLOG_USE_STD_FORMAT AND CMAKE_CXX_STANDARD LESS 20)
message(FATAL_ERROR "SPDLOG_USE_STD_FORMAT must be used with CMAKE_CXX_STANDARD >= 20")
endif()

# misc tweakme options
if(WIN32)
option(SPDLOG_WCHAR_FILENAMES "Support wchar filenames" OFF)
Expand Down

0 comments on commit ca49a12

Please sign in to comment.