diff options
author | Brad King <brad.king@kitware.com> | 2020-03-31 14:25:49 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2020-03-31 14:35:56 (GMT) |
commit | 4aaa9ea96c1e00237fa5d1ffd9e2938bc0d711e8 (patch) | |
tree | 5d2e5424f1d19fb67c52ac6fcce67fb27ae6fd43 /Modules/Compiler | |
parent | e3185e3d1b92a95c18f22f70b3cef6944dd019eb (diff) | |
download | CMake-4aaa9ea96c1e00237fa5d1ffd9e2938bc0d711e8.zip CMake-4aaa9ea96c1e00237fa5d1ffd9e2938bc0d711e8.tar.gz CMake-4aaa9ea96c1e00237fa5d1ffd9e2938bc0d711e8.tar.bz2 |
XL: C++14 language level flags are only available on Linux
Since commit 458ea9d76c (XL: Add C++14 language level flags, 2019-04-15,
v3.15.0-rc1~226^2) we use `-qlanglvl=extended1y` for C++14 with XL 16.1.
However, that flag is only supported on a Linux host.
Issue: #20521
Diffstat (limited to 'Modules/Compiler')
-rw-r--r-- | Modules/Compiler/XL-CXX.cmake | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/Compiler/XL-CXX.cmake b/Modules/Compiler/XL-CXX.cmake index 3037851..7641078 100644 --- a/Modules/Compiler/XL-CXX.cmake +++ b/Modules/Compiler/XL-CXX.cmake @@ -18,7 +18,7 @@ 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) + if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 16.1.0 AND CMAKE_SYSTEM_NAME STREQUAL "Linux") set(CMAKE_CXX14_STANDARD_COMPILE_OPTION "-qlanglvl=extended1y") set(CMAKE_CXX14_EXTENSION_COMPILE_OPTION "-qlanglvl=extended1y") set(CMAKE_CXX14_STANDARD__HAS_FULL_SUPPORT ON) |