Skip to content

Commit b870738

Browse files
Bump c++ version to 17
1 parent ec53d10 commit b870738

File tree

6 files changed

+8
-8
lines changed

6 files changed

+8
-8
lines changed

BuildTools/CMake/BuildUtils.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ function(set_common_target_properties TARGET)
160160

161161
get_target_property(TARGET_TYPE ${TARGET} TYPE)
162162

163-
set(CXX_STANDARD 14)
163+
set(CXX_STANDARD 17)
164164
if(MIN_CXX_STANDARD)
165165
if(MIN_CXX_STANDARD GREATER ${CXX_STANDARD})
166166
set(CXX_STANDARD ${MIN_CXX_STANDARD})
@@ -169,7 +169,7 @@ function(set_common_target_properties TARGET)
169169

170170
set_target_properties(${TARGET} PROPERTIES
171171
# It is crucial to set CXX_STANDARD flag to only affect c++ files and avoid failures compiling c-files:
172-
# error: invalid argument '-std=c++14' not allowed with 'C/ObjC'
172+
# error: invalid argument '-std=c++17' not allowed with 'C/ObjC'
173173
CXX_STANDARD ${CXX_STANDARD}
174174
CXX_STANDARD_REQUIRED ON
175175
)

Common/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ if(PLATFORM_LINUX)
9090
endif()
9191

9292
# c++ 17 is needed for aligned_alloc
93-
set_common_target_properties(Diligent-Common 17)
93+
set_common_target_properties(Diligent-Common)
9494

9595
source_group("src" FILES ${SOURCE})
9696
source_group("include" FILES ${INCLUDE})

Graphics/GraphicsEngineWebGPU/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,8 +165,8 @@ else()
165165
)
166166
endif()
167167

168-
set_common_target_properties(Diligent-GraphicsEngineWebGPU-shared 17)
169-
set_common_target_properties(Diligent-GraphicsEngineWebGPU-static 17)
168+
set_common_target_properties(Diligent-GraphicsEngineWebGPU-shared)
169+
set_common_target_properties(Diligent-GraphicsEngineWebGPU-static)
170170

171171
if (${DILIGENT_NO_GLSLANG})
172172
message("GLSLang is not being built. WebGPU backend will only be able to consume SPIRV byte code.")

Graphics/ShaderTools/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ add_custom_command(OUTPUT ${HLSL_DEFINITIONS_INC} # We must use full path here!
227227
VERBATIM
228228
)
229229

230-
set_common_target_properties(Diligent-ShaderTools 17)
230+
set_common_target_properties(Diligent-ShaderTools)
231231

232232
source_group("src" FILES ${SOURCE})
233233
source_group("include" FILES ${INCLUDE})

Tests/DiligentCoreTest/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ if (CMAKE_CXX_COMPILER_ID MATCHES "Clang")
3232
endif()
3333

3434
add_executable(DiligentCoreTest ${SOURCE} ${SHADERS})
35-
set_common_target_properties(DiligentCoreTest 17)
35+
set_common_target_properties(DiligentCoreTest)
3636

3737
if (PLATFORM_WEB)
3838
set(RESOURCE_PATH "${PROJECT_SOURCE_DIR}/assets/")

Tests/TestFramework/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ set(INCLUDE
1414

1515
set(ALL_SOURCE ${SOURCE} ${INCLUDE})
1616
add_library(Diligent-TestFramework STATIC ${ALL_SOURCE})
17-
set_common_target_properties(Diligent-TestFramework 17)
17+
set_common_target_properties(Diligent-TestFramework)
1818

1919
target_link_libraries(Diligent-TestFramework
2020
PRIVATE

0 commit comments

Comments
 (0)