summaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt12
1 files changed, 8 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6b88538..eb46c3b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -55,11 +55,15 @@ if(NOT DEFINED CMAKE_C_STANDARD AND NOT CMake_NO_C_STANDARD)
endif()
endif()
if(NOT DEFINED CMAKE_CXX_STANDARD AND NOT CMake_NO_CXX_STANDARD)
- include(${CMake_SOURCE_DIR}/Source/Checks/cm_cxx14_cstdio.cmake)
- if(NOT CMake_CXX14_CSTDIO_BROKEN)
- set(CMAKE_CXX_STANDARD 14)
+ if (CMAKE_CXX_COMPILER_ID STREQUAL SunPro AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.14)
+ set(CMAKE_CXX_STANDARD 98)
else()
- set(CMAKE_CXX_STANDARD 11)
+ include(${CMake_SOURCE_DIR}/Source/Checks/cm_cxx14_cstdio.cmake)
+ if(NOT CMake_CXX14_CSTDIO_BROKEN)
+ set(CMAKE_CXX_STANDARD 14)
+ else()
+ set(CMAKE_CXX_STANDARD 11)
+ endif()
endif()
endif()
if(NOT CMake_TEST_EXTERNAL_CMAKE)