Skip to content
Snippets Groups Projects
Commit 49729176 authored by Stéphane Del Pino's avatar Stéphane Del Pino
Browse files

added -Wno-c++17-extensions for cmake (<3.8) support

parent b3dd88ff
No related branches found
No related tags found
No related merge requests found
......@@ -54,6 +54,11 @@ if(${OPENMP_FOUND})
set(KOKKOS_ENABLE_OPENMP ON CACHE BOOL "")
endif()
# Kokkso compiler flags
add_subdirectory(${PASTIS_SOURCE_DIR}/packages/kokkos)
include_directories(${Kokkos_INCLUDE_DIRS_RET})
include(GetKokkosCompilerFlags)
# sets Kokkos debug flags when non release build
if (CMAKE_BUILD_TYPE MATCHES "Release")
set (KOKKOS_ENABLE_DEBUG OFF)
......@@ -65,16 +70,13 @@ endif()
if(${CMAKE_VERSION} VERSION_LESS "3.8.0")
message(WARNING "Please consider to switch to CMake >= 3.8")
set(PASTIS_CXX_FLAGS "${PASTIS_CXX_FLAGS} -std=gnu++1z")
if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
set(PASTIS_CXX_FLAGS "${PASTIS_CXX_FLAGS} -Wno-c++17-extensions")
endif()
else()
set(CMAKE_CXX_STANDARD "17")
endif()
add_subdirectory(${PASTIS_SOURCE_DIR}/packages/kokkos)
include_directories(${Kokkos_INCLUDE_DIRS_RET})
# Kokkso compiler flags
include(GetKokkosCompilerFlags)
# Compiler flags
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${PASTIS_CXX_FLAGS}")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment