diff options
author | Brad King <brad.king@kitware.com> | 2018-03-26 18:27:12 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2018-03-27 11:42:07 (GMT) |
commit | 71cb8ce3a1e1c41ffcd43760609defc574d2a65b (patch) | |
tree | 220d77340d84294031e167b1376e55c8a9da987b /Modules/Compiler | |
parent | 8f146c45087bae5869f95cebce84134c917d28bf (diff) | |
download | CMake-71cb8ce3a1e1c41ffcd43760609defc574d2a65b.zip CMake-71cb8ce3a1e1c41ffcd43760609defc574d2a65b.tar.gz CMake-71cb8ce3a1e1c41ffcd43760609defc574d2a65b.tar.bz2 |
Features: Activate C++ 20 support for GNU 8.0+
Diffstat (limited to 'Modules/Compiler')
-rw-r--r-- | Modules/Compiler/GNU-CXX.cmake | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Modules/Compiler/GNU-CXX.cmake b/Modules/Compiler/GNU-CXX.cmake index 0b15d25..0058223 100644 --- a/Modules/Compiler/GNU-CXX.cmake +++ b/Modules/Compiler/GNU-CXX.cmake @@ -41,4 +41,9 @@ elseif (NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.1) set(CMAKE_CXX17_EXTENSION_COMPILE_OPTION "-std=gnu++1z") endif() +if (NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS 8.0) + set(CMAKE_CXX20_STANDARD_COMPILE_OPTION "-std=c++2a") + set(CMAKE_CXX20_EXTENSION_COMPILE_OPTION "-std=gnu++2a") +endif() + __compiler_check_default_language_standard(CXX 3.4 98 6.0 14) |