Mercurial > hg > orthanc-stone
diff Samples/WebAssembly/CMakeLists.txt @ 828:28f99af358fa
Merge + FusionMprSdl
author | Benjamin Golinvaux <bgo@osimis.io> |
---|---|
date | Wed, 29 May 2019 16:15:04 +0200 |
parents | 270c31978df1 |
children | 2de01660debe |
line wrap: on
line diff
--- a/Samples/WebAssembly/CMakeLists.txt Wed May 29 13:44:55 2019 +0200 +++ b/Samples/WebAssembly/CMakeLists.txt Wed May 29 16:15:04 2019 +0200 @@ -13,6 +13,7 @@ set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -s ERROR_ON_UNDEFINED_SYMBOLS=1") set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -s ALLOW_MEMORY_GROWTH=1") set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -s ASSERTIONS=1 -s DISABLE_EXCEPTION_CATCHING=0") +#set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -s EXIT_RUNTIME=1") ##################################################################### @@ -68,20 +69,40 @@ ${ORTHANC_STONE_SOURCES} ) -add_executable(BasicScene - BasicScene.cpp - ) + +if (OFF) + add_executable(BasicScene + BasicScene.cpp + ) + + target_link_libraries(BasicScene OrthancStone) + + install( + TARGETS BasicScene + RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX} + ) +endif() -target_link_libraries(BasicScene OrthancStone) + +if (ON) + add_executable(BasicMPR + BasicMPR.cpp + ) -install( - TARGETS BasicScene - RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX} - ) + target_link_libraries(BasicMPR OrthancStone) + + install( + TARGETS BasicMPR + RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX} + ) +endif() + install( FILES + ${CMAKE_CURRENT_BINARY_DIR}/BasicMPR.wasm ${CMAKE_CURRENT_BINARY_DIR}/BasicScene.wasm + ${CMAKE_SOURCE_DIR}/BasicMPR.html ${CMAKE_SOURCE_DIR}/BasicScene.html ${CMAKE_SOURCE_DIR}/Configuration.json ${CMAKE_SOURCE_DIR}/index.html