File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -61,6 +61,13 @@ function(cxx_qt_import_crate)
61
61
"QMAKE=${IMPORT_CRATE_QMAKE} "
62
62
$< $< BOOL:${CMAKE_RUSTC_WRAPPER} > :RUSTC_WRAPPER=${CMAKE_RUSTC_WRAPPER} > )
63
63
64
+ # When using WASM ensure that we have RUST_CXX_NO_EXCEPTIONS set
65
+ if (${CMAKE_SYSTEM_NAME} MATCHES "Emscripten" )
66
+ set (EMSCRIPTEN_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DRUST_CXX_NO_EXCEPTIONS" )
67
+ message (STATUS "CXX-Qt Found Emscripten, setting CXXFLAGS=${EMSCRIPTEN_CXX_FLAGS} " )
68
+ corrosion_set_env_vars (${CRATE} "CXXFLAGS=${EMSCRIPTEN_CXX_FLAGS} " )
69
+ endif ()
70
+
64
71
file (MAKE_DIRECTORY "${IMPORT_CRATE_CXX_QT_EXPORT_DIR} /crates/${CRATE} /include/" )
65
72
target_include_directories (${CRATE} INTERFACE "${IMPORT_CRATE_CXX_QT_EXPORT_DIR} /crates/${CRATE} /include/" )
66
73
You can’t perform that action at this time.
0 commit comments