[Web] Force emcc to use "wasm" longjmp mode#1489
Conversation
SUPPORT_LONGJMP have changed since emscripten 3.1.32 to default to "wasm" mode when exceptions are enabled, and "emscripten" mode when disabled. While we generally doesn't use exception in core, linked libraries may need them, and emscripten don't plan to support WASM EH + Emscripten SjLj in the long term.
dsnopek
left a comment
There was a problem hiding this comment.
Thanks! This looks good to me :-)
I'm going to hold off on merging until after the Godot PR is merged (although, it seems like that'll happen soon)
|
I'm not sure if this one should really be cherry-picked? Does this option need to be matched with a Godot that's also built with this option? If so, I guess we can't cherry-pick it unless Godot cherry-picks the corresponding change. |
|
@Faless Is this a change that should be cherry-picked? |
Yes, I would cherry pick it. If you are targeting 4.1 or 4.2, it won't matter since the flag is already default in emcc for pthreads builds (and 4.1/4.2 did not support single threaded builds). But if you use an old godot-cpp to target better minimum compatibility for other platforms, you will (hopefully) be able to use it to target modern wasm builds. |
|
Thanks! Cherry-picked for 4.2 in PR #1570 |
|
Cherry-picked for 4.1 in PR #1572 |
SUPPORT_LONGJMPhave changed since emscripten 3.1.32 to default to"wasm"mode when exceptions are enabled, and"emscripten"mode when disabled.While we generally don't use exception in core, linked libraries may need them, and emscripten doesn't plan to support WASM EH + Emscripten SjLj in the long term.
See godotengine/godot#93143