File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -121,6 +121,7 @@ endforeach()
121121set (CMAKE_MODULE_PATH "${CMAKE_MODULE_PATH } " "${CMAKE_SOURCE_DIR } /modules" )
122122
123123add_library (xtensor-io INTERFACE )
124+ target_compile_features (xtensor-io INTERFACE cxx_std_17 )
124125
125126include_directories (${GTEST_INCLUDE_DIRS} )
126127
Original file line number Diff line number Diff line change 77# The full license is in the file LICENSE, distributed with this software. #
88############################################################################
99
10- cmake_minimum_required (VERSION 3.8 )
10+ cmake_minimum_required (VERSION 3.30 )
1111
1212if (CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR )
1313 project (xtensor-io-test)
@@ -25,12 +25,12 @@ string(TOUPPER "${CMAKE_BUILD_TYPE}" U_CMAKE_BUILD_TYPE)
2525
2626if (CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR CMAKE_CXX_COMPILER_ID MATCHES "GNU" OR CMAKE_CXX_COMPILER_ID MATCHES "Intel" )
2727 set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS } -march=native -Wunused-parameter -Wextra -Wreorder -Wconversion -Wsign-conversion" )
28- CHECK_CXX_COMPILER_FLAG ("-std=c++14" HAS_CPP14_FLAG )
28+ CHECK_CXX_COMPILER_FLAG ("-std=c++17" HAS_CPP17_FLAG )
2929
30- if (HAS_CPP14_FLAG )
31- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS } -std=c++14 " )
30+ if (HAS_CPP17_FLAG )
31+ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS } -std=c++17 " )
3232 else ()
33- message (FATAL_ERROR "Unsupported compiler -- xtensor requires C++14 support!" )
33+ message (FATAL_ERROR "Unsupported compiler -- xtensor requires C++17 support!" )
3434 endif ()
3535endif ()
3636
You can’t perform that action at this time.
0 commit comments