diff options
author | Brad King <brad.king@kitware.com> | 2018-01-29 13:04:22 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2018-01-29 13:04:28 (GMT) |
commit | a271286f417731916cd60c546665ec030bc5b2c7 (patch) | |
tree | b3dbdadfeecfcc94a0aef881368fd7b990bd46e3 /Modules/Compiler/Intel-CXX.cmake | |
parent | 53f77fad2f305d84b7cc7a15ebee6fa0afbd237e (diff) | |
parent | c3d576f5d685f2703ebed0dd0e76209b0fd6e6cf (diff) | |
download | CMake-a271286f417731916cd60c546665ec030bc5b2c7.zip CMake-a271286f417731916cd60c546665ec030bc5b2c7.tar.gz CMake-a271286f417731916cd60c546665ec030bc5b2c7.tar.bz2 |
Merge topic 'intel-cxx17-flags'
c3d576f5 Intel: Add C++17 compiler options
4a5727d3 Intel: Correct the C11 ext flag
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1711
Diffstat (limited to 'Modules/Compiler/Intel-CXX.cmake')
-rw-r--r-- | Modules/Compiler/Intel-CXX.cmake | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/Modules/Compiler/Intel-CXX.cmake b/Modules/Compiler/Intel-CXX.cmake index 0eb9e1f..d9c5749 100644 --- a/Modules/Compiler/Intel-CXX.cmake +++ b/Modules/Compiler/Intel-CXX.cmake @@ -9,6 +9,11 @@ set(CMAKE_DEPFILE_FLAGS_CXX "-MD -MT <OBJECT> -MF <DEPFILE>") if("x${CMAKE_CXX_SIMULATE_ID}" STREQUAL "xMSVC") + if (NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 18.0.0) + set(CMAKE_CXX17_STANDARD_COMPILE_OPTION "-Qstd=c++17") + set(CMAKE_CXX17_EXTENSION_COMPILE_OPTION "-Qstd=c++17") + endif() + if (NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 16.0) set(CMAKE_CXX14_STANDARD_COMPILE_OPTION "-Qstd=c++14") set(CMAKE_CXX14_EXTENSION_COMPILE_OPTION "-Qstd=c++14") @@ -29,6 +34,12 @@ if("x${CMAKE_CXX_SIMULATE_ID}" STREQUAL "xMSVC") else() + if (NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 18.0.0) + set(CMAKE_CXX17_STANDARD_COMPILE_OPTION "-std=c++17") + # todo: there is no gnu++17 value supported; figure out what to do + set(CMAKE_CXX17_EXTENSION_COMPILE_OPTION "-std=c++17") + endif() + if (NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 15.0.2) set(CMAKE_CXX14_STANDARD_COMPILE_OPTION "-std=c++14") # todo: there is no gnu++14 value supported; figure out what to do |