add wasm options
This commit is contained in:
2026-02-14 14:31:28 +01:00
parent 58cd5ac07c
commit 61b758c333
+6 -4
View File
@@ -7,12 +7,10 @@ add_subdirectory(qwt)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}) include_directories(${CMAKE_CURRENT_SOURCE_DIR})
file(GLOB_RECURSE ui "ui/*.[hc]pp") file(GLOB_RECURSE ui "ui/*")
file(GLOB_RECURSE ui_ui "ui/*.ui")
set(PROJECT_SOURCES set(PROJECT_SOURCES
${ui} ${ui}
${ui_ui}
helpers.cpp helpers.cpp
helpers.hpp helpers.hpp
IterableEnum.hpp IterableEnum.hpp
@@ -29,8 +27,8 @@ set(PROJECT_SOURCES
web_socket_wrapper.hpp web_socket_wrapper.hpp
) )
if (NOT EMSCRIPTEN)
file(GLOB_RECURSE sims "simulators/*.cpp") file(GLOB_RECURSE sims "simulators/*.cpp")
# Loop through each .cpp file and create a library for it # Loop through each .cpp file and create a library for it
foreach(sim ${sims}) foreach(sim ${sims})
# Extract the base name of the file (without the directory and extension) # Extract the base name of the file (without the directory and extension)
@@ -49,11 +47,15 @@ foreach(sim ${sims})
AUTORCC ON AUTORCC ON
) )
endforeach() endforeach()
else()
file(GLOB_RECURSE sims "simulators/*")
endif()
if(${QT_VERSION_MAJOR} GREATER_EQUAL 6) if(${QT_VERSION_MAJOR} GREATER_EQUAL 6)
qt_add_executable(Simulator-CVS_I10 qt_add_executable(Simulator-CVS_I10
MANUAL_FINALIZATION MANUAL_FINALIZATION
${PROJECT_SOURCES} ${PROJECT_SOURCES}
$<$<BOOL:${EMSCRIPTEN}>:${sims}>
) )
# Define target properties for Android with Qt 6 as: # Define target properties for Android with Qt 6 as:
# set_property(TARGET Simulator - CVS_I10 APPEND PROPERTY QT_ANDROID_PACKAGE_SOURCE_DIR # set_property(TARGET Simulator - CVS_I10 APPEND PROPERTY QT_ANDROID_PACKAGE_SOURCE_DIR