File tree Expand file tree Collapse file tree 2 files changed +1
-17
lines changed
Expand file tree Collapse file tree 2 files changed +1
-17
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ cmake_minimum_required(VERSION 3.18)
22
33cmake_policy (SET CMP0011 NEW)
44cmake_policy (SET CMP0025 NEW)
5+ cmake_policy (SET CMP0067 NEW)
56
67# Avoid source tree pollution
78set (CMAKE_DISABLE_SOURCE_CHANGES ON )
Original file line number Diff line number Diff line change 1- include (CheckCXXCompilerFlag)
21include (CpuMarch)
3- include (CheckCXXCompilerFlagAndEnableIt)
4-
5- # yes, need to keep both the CMAKE_CXX_FLAGS and CMAKE_CXX_STANDARD.
6- # with just the CMAKE_CXX_STANDARD, try_compile() breaks:
7- # https://gitlab.kitware.com/cmake/cmake/issues/16456
8- # with just the CMAKE_CXX_FLAGS, 'bundled' pugixml breaks tests
9- # https://github.com/darktable-org/rawspeed/issues/112#issuecomment-321517003
10-
11- message (STATUS "Checking for -std=c++17 support" )
12- CHECK_CXX_COMPILER_FLAG("-std=c++17" COMPILER_SUPPORTS_CXX17)
13- if (NOT COMPILER_SUPPORTS_CXX17)
14- message (FATAL_ERROR "The compiler ${CMAKE_CXX_COMPILER} has no C++17 support. Please use a different C++ compiler." )
15- else ()
16- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++17" )
17- message (STATUS "Checking for -std=c++17 support - works" )
18- endif ()
192
203set (CMAKE_CXX_STANDARD 17)
214set (CMAKE_CXX_STANDARD_REQUIRED ON )
You can’t perform that action at this time.
0 commit comments