summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-04-18 15:03:01 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-04-18 15:03:12 (GMT)
commita000ec7a087b8d221f52960abc5a9785e27551e2 (patch)
treea9fe303251dce9bd44896c0105fa723ef0325927
parent52ef218664ff3bb4c162cf9e722756a22e6dc2e3 (diff)
parent458ea9d76c42b982b48104e700d844a50dc4978c (diff)
downloadCMake-a000ec7a087b8d221f52960abc5a9785e27551e2.zip
CMake-a000ec7a087b8d221f52960abc5a9785e27551e2.tar.gz
CMake-a000ec7a087b8d221f52960abc5a9785e27551e2.tar.bz2
Merge topic 'add_xl_cxx14_support'
458ea9d76c XL: Add C++14 language level flags Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3235
-rw-r--r--Help/release/dev/xl-supports-cxx14.rst4
-rw-r--r--Modules/Compiler/XL-CXX.cmake5
-rw-r--r--Modules/Compiler/XLClang-CXX.cmake4
3 files changed, 13 insertions, 0 deletions
diff --git a/Help/release/dev/xl-supports-cxx14.rst b/Help/release/dev/xl-supports-cxx14.rst
new file mode 100644
index 0000000..a18e0ad
--- /dev/null
+++ b/Help/release/dev/xl-supports-cxx14.rst
@@ -0,0 +1,4 @@
+xlc-supports-cxx14
+----------------------
+
+* IBM AIX XL compiler have learned how to compile C++14.
diff --git a/Modules/Compiler/XL-CXX.cmake b/Modules/Compiler/XL-CXX.cmake
index ec3f1f8..3037851 100644
--- a/Modules/Compiler/XL-CXX.cmake
+++ b/Modules/Compiler/XL-CXX.cmake
@@ -18,6 +18,11 @@ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 10.1)
set(CMAKE_CXX11_EXTENSION_COMPILE_OPTION "-qlanglvl=extended0x")
set(CMAKE_CXX98_STANDARD__HAS_FULL_SUPPORT ON)
set(CMAKE_CXX11_STANDARD__HAS_FULL_SUPPORT ON)
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 16.1.0)
+ set(CMAKE_CXX14_STANDARD_COMPILE_OPTION "-qlanglvl=extended1y")
+ set(CMAKE_CXX14_EXTENSION_COMPILE_OPTION "-qlanglvl=extended1y")
+ set(CMAKE_CXX14_STANDARD__HAS_FULL_SUPPORT ON)
+ endif()
endif ()
__compiler_check_default_language_standard(CXX 10.1 98)
diff --git a/Modules/Compiler/XLClang-CXX.cmake b/Modules/Compiler/XLClang-CXX.cmake
index 03c7c7b..9ea3d7c 100644
--- a/Modules/Compiler/XLClang-CXX.cmake
+++ b/Modules/Compiler/XLClang-CXX.cmake
@@ -15,6 +15,10 @@ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 13.1.1)
set(CMAKE_CXX14_EXTENSION_COMPILE_OPTION "-std=gnu++1y")
set(CMAKE_CXX14_STANDARD__HAS_FULL_SUPPORT ON)
endif ()
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 16.1.0)
+ set(CMAKE_CXX14_STANDARD_COMPILE_OPTION "-std=c++14")
+ set(CMAKE_CXX14_EXTENSION_COMPILE_OPTION "-std=gnu++14")
+ endif()
endif()
__compiler_check_default_language_standard(CXX 13.1.1 98)