summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2014-09-22 13:12:56 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2014-09-22 13:12:56 (GMT)
commitd4713b84b70ffc7da81f8b247f943fa93bd5899f (patch)
tree2115e5b9b8e5bc8108205a48e7a03eb5a5b9c86b /Modules
parentf28ebcbf1b59fad51833aead76e4f733d7292503 (diff)
parent49b8140e5db355229dd2984967e8a08713c9ea9b (diff)
downloadCMake-d4713b84b70ffc7da81f8b247f943fa93bd5899f.zip
CMake-d4713b84b70ffc7da81f8b247f943fa93bd5899f.tar.gz
CMake-d4713b84b70ffc7da81f8b247f943fa93bd5899f.tar.bz2
Merge topic 'clang-compile-options-cxx14'
49b8140e Clang: Enable c++14 dialect flag with Clang 3.5. 0b80fc35 Clang: Don't overwrite c++11 compile option value with c++14 flag.
Diffstat (limited to 'Modules')
-rw-r--r--Modules/Compiler/Clang-CXX.cmake9
1 files changed, 6 insertions, 3 deletions
diff --git a/Modules/Compiler/Clang-CXX.cmake b/Modules/Compiler/Clang-CXX.cmake
index bdb6d69..5dd7b4a 100644
--- a/Modules/Compiler/Clang-CXX.cmake
+++ b/Modules/Compiler/Clang-CXX.cmake
@@ -23,9 +23,12 @@ elseif(NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 2.1)
set(CMAKE_CXX11_EXTENSION_COMPILE_OPTION "-std=gnu++0x")
endif()
-if(NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 3.4)
- set(CMAKE_CXX11_STANDARD_COMPILE_OPTION "-std=c++1y")
- set(CMAKE_CXX11_EXTENSION_COMPILE_OPTION "-std=gnu++1y")
+if(NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 3.5)
+ set(CMAKE_CXX14_STANDARD_COMPILE_OPTION "-std=c++14")
+ set(CMAKE_CXX14_EXTENSION_COMPILE_OPTION "-std=gnu++14")
+elseif(NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 3.4)
+ set(CMAKE_CXX14_STANDARD_COMPILE_OPTION "-std=c++1y")
+ set(CMAKE_CXX14_EXTENSION_COMPILE_OPTION "-std=gnu++1y")
endif()
set(CMAKE_CXX_STANDARD_DEFAULT 98)