@@ -54,8 +54,8 @@ option(XEUS_CPP_BUILD_STATIC "Build xeus-cpp static library" ON)
5454option (XEUS_CPP_BUILD_SHARED "Split xcpp build into executable and library" ON )
5555option (XEUS_CPP_BUILD_EXECUTABLE "Build the xcpp executable" ON )
5656
57- option (XEUS_CPP_USE_SHARED_XEUS "Link xcpp with the xeus shared library (instead of the static library)" ON )
58- option (XEUS_CPP_USE_SHARED_XEUS_CPP "Link xcpp with the xeus shared library (instead of the static library)" ON )
57+ option (XEUS_CPP_USE_SHARED_XEUS "Link xcpp with the xeus shared library (instead of the static library)" ON )
58+ option (XEUS_CPP_USE_SHARED_XEUS_CPP "Link xcpp with the xeus-cpp shared library (instead of the static library)" ON )
5959option (XEUS_CPP_EMSCRIPTEN_WASM_BUILD "Build for wasm with emscripten" OFF )
6060
6161# Test options
@@ -77,10 +77,11 @@ endif()
7777if (EMSCRIPTEN)
7878 add_compile_definitions (XEUS_CPP_EMSCRIPTEN_WASM_BUILD)
7979 message ("Build with emscripten" )
80+ set_property (GLOBAL PROPERTY TARGET_SUPPORTS_SHARED_LIBS TRUE )
8081 set (XEUS_CPP_BUILD_STATIC ON )
8182 set (XEUS_CPP_BUILD_SHARED OFF )
8283 set (XEUS_CPP_BUILD_EXECUTABLE OFF )
83- set (XEUS_CPP_USE_SHARED_XEUS OFF )
84+ set (XEUS_CPP_USE_SHARED_XEUS ON )
8485 set (XEUS_CPP_USE_SHARED_XEUS_CPP OFF )
8586 # ENV (https://github.com/emscripten-core/emscripten/commit/6d9681ad04f60b41ef6345ab06c29bbc9eeb84e0)
8687 set (EMSCRIPTEN_FEATURES "${EMSCRIPTEN_FEATURES} -s \" EXPORTED_RUNTIME_METHODS=[ENV']\" " )
@@ -546,4 +547,4 @@ if(EMSCRIPTEN)
546547 "$<TARGET_FILE_DIR:xcpp>/xcpp.wasm"
547548 "$<TARGET_FILE_DIR:xcpp>/xcpp.data"
548549 DESTINATION ${CMAKE_INSTALL_BINDIR} )
549- endif ()
550+ endif ()
0 commit comments