Codechange: switch to C++17 on all platforms.

pull/217/head
frosch 4 years ago committed by Michael Lutz
parent c9fd85528a
commit 5d278b62cc

@ -32,14 +32,7 @@ set_directory_options()
include(Static) include(Static)
set_static_if_needed() set_static_if_needed()
if(MSVC) set(CMAKE_CXX_STANDARD 17)
# C++17 for MSVC
set(CMAKE_CXX_STANDARD 17)
else()
# C++11 for all other targets
set(CMAKE_CXX_STANDARD 11)
endif()
set(CMAKE_CXX_STANDARD_REQUIRED YES) set(CMAKE_CXX_STANDARD_REQUIRED YES)
set(CMAKE_CXX_EXTENSIONS NO) set(CMAKE_CXX_EXTENSIONS NO)

@ -83,9 +83,9 @@ make
## Supported compilers ## Supported compilers
Every compiler that is supported by CMake and supports C++11, should be Every compiler that is supported by CMake and supports C++17, should be
able to compile OpenTTD. As the exact list of compilers changes constantly, able to compile OpenTTD. As the exact list of compilers changes constantly,
we refer to the compiler manual to see if it supports C++11, and to CMake we refer to the compiler manual to see if it supports C++17, and to CMake
to see if it supports your compiler. to see if it supports your compiler.
## Compilation of base sets ## Compilation of base sets

Loading…
Cancel
Save