Skip to content

Define STANDALONE_WASM at compile time as well as link time#1261

Closed
martijneken wants to merge 1 commit intoemscripten-core:mainfrom
martijneken:standalone-wasm-compile
Closed

Define STANDALONE_WASM at compile time as well as link time#1261
martijneken wants to merge 1 commit intoemscripten-core:mainfrom
martijneken:standalone-wasm-compile

Conversation

@martijneken
Copy link
Contributor

This fixes libraries using conditional dependencies, such as Abseil: https://github.com/search?q=repo%3Aabseil%2Fabseil-cpp+standalone_wasm&type=code

This fixes libraries using conditional dependencies, such as Abseil:
https://github.com/search?q=repo%3Aabseil%2Fabseil-cpp+standalone_wasm&type=code

Signed-off-by: Martijn Stevenson <mstevenson@google.com>
@walkingeyerobot walkingeyerobot self-requested a review July 28, 2023 19:59
@walkingeyerobot
Copy link
Collaborator

Thanks for the PR. This is correct given the current state of the world. However, after talking to some of the other maintainers, I don't think emscripten wants to commit to STANDALONE_WASM being detected like this, and I was a bit too quick to add that #ifdef to absl. Instead, I'm going to remove the #ifdef that checks for STANDALONE_WASM from absl and improve their code so that it continues to work with JS contexts via EM_JS but also doesn't crash if being built for standalone mode.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants