Skip to content

Commit 6c0273f

Browse files
author
Test User
committed
Change CXX standard using property
1 parent 457aec9 commit 6c0273f

2 files changed

Lines changed: 3 additions & 5 deletions

File tree

CMakeLists.txt

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,7 @@ endif()
1313
list(APPEND CMAKE_MODULE_PATH
1414
"${CMAKE_SOURCE_DIR}/cmake/")
1515

16-
if(EMSCRIPTEN)
17-
set(CMAKE_CXX_STANDARD 17)
18-
else()
19-
set(CMAKE_CXX_STANDARD 11)
20-
endif()
16+
set(CMAKE_CXX_STANDARD 11)
2117
set(CMAKE_CXX_STANDARD_REQUIRED YES)
2218

2319
# for /MT on MSVC

src/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -313,6 +313,8 @@ if(ENABLE_GUI)
313313
message(FATAL_ERROR "The Emscripten build requires at least version 4.0.8")
314314
endif()
315315

316+
target_compile_features(solvespace PRIVATE cxx_std_17)
317+
316318
set(SHELL "${CMAKE_CURRENT_SOURCE_DIR}/platform/html/emshell.html")
317319
# Add internal quotes to paths used in the response file to ensure that paths
318320
# that contain spaces are handled correctly

0 commit comments

Comments
 (0)