diff options
author | Brad King <brad.king@kitware.com> | 2015-07-10 12:51:09 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2015-07-10 12:51:09 (GMT) |
commit | 2ffa8ae29c3caa192eed47399c87680af09d08f0 (patch) | |
tree | 8aa343b4bf3d965b07a14f9a74f56e080904bc33 | |
parent | 9f9d26465fec48f9fe3310079c2414b314feaab1 (diff) | |
parent | 228643af6d8c0e29735c3fdf7b25c161a11a68c9 (diff) | |
download | CMake-2ffa8ae29c3caa192eed47399c87680af09d08f0.zip CMake-2ffa8ae29c3caa192eed47399c87680af09d08f0.tar.gz CMake-2ffa8ae29c3caa192eed47399c87680af09d08f0.tar.bz2 |
Merge topic 'compiler-feature-AppleClang-std-flags'
228643af AppleClang: Use modern C++14 standard flags for Apple Clang 6.1
-rw-r--r-- | Modules/Compiler/AppleClang-CXX.cmake | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Modules/Compiler/AppleClang-CXX.cmake b/Modules/Compiler/AppleClang-CXX.cmake index 5194da4..1ba8a77 100644 --- a/Modules/Compiler/AppleClang-CXX.cmake +++ b/Modules/Compiler/AppleClang-CXX.cmake @@ -13,7 +13,10 @@ if(NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 4.0) set(CMAKE_CXX11_EXTENSION_COMPILE_OPTION "-std=gnu++11") endif() -if(NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.1) +if(NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 6.1) + 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 5.1) # AppleClang 5.0 knows this flag, but does not set a __cplusplus macro greater than 201103L set(CMAKE_CXX14_STANDARD_COMPILE_OPTION "-std=c++1y") set(CMAKE_CXX14_EXTENSION_COMPILE_OPTION "-std=gnu++1y") |