From b1f73f0c337ad7fa040dfde8f6fdf7be53512875 Mon Sep 17 00:00:00 2001 From: Jack Andersen Date: Sat, 17 Jun 2017 16:50:29 -1000 Subject: [PATCH] apply CMAKE_CXX_STANDARD --- CMakeLists.txt | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 1787b3a..eead7f8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,8 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR) -cmake_minimum_required(VERSION 3.0) +cmake_minimum_required(VERSION 3.1.0 FATAL_ERROR) # because of CMAKE_CXX_STANDARD project(athena) +set(CMAKE_CXX_STANDARD 14) +set(CMAKE_CXX_STANDARD_REQUIRED ON) endif() ################## @@ -21,10 +23,6 @@ add_subdirectory(extern) include_directories(include ${LZO_INCLUDE_DIR} ${ZLIB_INCLUDE_DIR}) -if (NOT MSVC) -set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14") -endif() - if(WIN32) list(APPEND CORE_EXTRA src/win32_largefilewrapper.c include/win32_largefilewrapper.h src/athena/FileWriterWin32.cpp src/athena/FileReaderWin32.cpp)