From 7da5dcd6f79085d0a5d2eb4b5faefbc6387dc769 Mon Sep 17 00:00:00 2001 From: Stephane Del Pino <stephane.delpino44@gmail.com> Date: Sat, 15 Aug 2020 19:22:33 +0200 Subject: [PATCH] Update CMake, gcc and clang minimal versions New requirements - CMake 3.10 - gcc 8 - clang 8 --- CMakeLists.txt | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 73cda5739..4197fca78 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required (VERSION 3.4) +cmake_minimum_required (VERSION 3.10) # CMake utils list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") @@ -81,8 +81,8 @@ endif() #------------------------------------------------------ # Checks if compiler version is compatible with Pugs sources -set(GNU_CXX_MIN_VERSION "7.0.0") -set(CLANG_CXX_MIN_VERSION "5.0.0") +set(GNU_CXX_MIN_VERSION "8.0.0") +set(CLANG_CXX_MIN_VERSION "8.0.0") # Pugs default compiler flags set(PUGS_CXX_FLAGS "${PUGS_CXX_FLAGS} -Wall -Wextra -pedantic") @@ -181,15 +181,7 @@ endif() #------------------------------------------------------ # C++ 17 flags -if(${CMAKE_VERSION} VERSION_LESS "3.8.0") - message(WARNING "Please consider to switch to CMake >= 3.8") - set(PUGS_CXX_FLAGS "${PUGS_CXX_FLAGS} -std=gnu++1z") - if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang") - set(PUGS_CXX_FLAGS "${PUGS_CXX_FLAGS} -Wno-c++17-extensions") - endif() -else() - set(CMAKE_CXX_STANDARD "17") -endif() +set(CMAKE_CXX_STANDARD "17") #------------------------------------------------------ # Kokkos configuration -- GitLab