setting the cmake standard to 20 when using std format (#2680)
This commit is contained in:
		@@ -25,7 +25,10 @@ endif()
 | 
				
			|||||||
# ---------------------------------------------------------------------------------------
 | 
					# ---------------------------------------------------------------------------------------
 | 
				
			||||||
# Compiler config
 | 
					# Compiler config
 | 
				
			||||||
# ---------------------------------------------------------------------------------------
 | 
					# ---------------------------------------------------------------------------------------
 | 
				
			||||||
if(NOT CMAKE_CXX_STANDARD)
 | 
					if(SPDLOG_USE_STD_FORMAT)
 | 
				
			||||||
 | 
					    set(CMAKE_CXX_STANDARD 20)
 | 
				
			||||||
 | 
					    set(CMAKE_CXX_STANDARD_REQUIRED ON)
 | 
				
			||||||
 | 
					elseif(NOT CMAKE_CXX_STANDARD)
 | 
				
			||||||
    set(CMAKE_CXX_STANDARD 11)
 | 
					    set(CMAKE_CXX_STANDARD 11)
 | 
				
			||||||
    set(CMAKE_CXX_STANDARD_REQUIRED ON)
 | 
					    set(CMAKE_CXX_STANDARD_REQUIRED ON)
 | 
				
			||||||
endif()
 | 
					endif()
 | 
				
			||||||
@@ -256,11 +259,6 @@ if(SPDLOG_NO_EXCEPTIONS AND NOT MSVC)
 | 
				
			|||||||
    target_compile_options(spdlog PRIVATE -fno-exceptions)
 | 
					    target_compile_options(spdlog PRIVATE -fno-exceptions)
 | 
				
			||||||
endif()
 | 
					endif()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
if(SPDLOG_USE_STD_FORMAT)
 | 
					 | 
				
			||||||
    set(CMAKE_CXX_STANDARD 20)
 | 
					 | 
				
			||||||
    set(CMAKE_CXX_STANDARD_REQUIRED ON)
 | 
					 | 
				
			||||||
endif()
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# ---------------------------------------------------------------------------------------
 | 
					# ---------------------------------------------------------------------------------------
 | 
				
			||||||
# Build binaries
 | 
					# Build binaries
 | 
				
			||||||
# ---------------------------------------------------------------------------------------
 | 
					# ---------------------------------------------------------------------------------------
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user