C++14 is a first class citizen in Xcode 6.




*diff --git a/Modules/Compiler/AppleClang-CXX.cmake 
b/Modules/Compiler/AppleClang-
CXX.cmake* *index 5194da4..27e4d8a 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.0)


+  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")


Attachment: AppleClang-CXX.cmake.diff
Description: Binary data

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers

Reply via email to