Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add wasm ctor and dtor calls to non-main exports in core #481

Merged
merged 1 commit into from
Sep 22, 2023

Conversation

jeffcharles
Copy link
Collaborator

Description of the change

Adds calls to __wasm_call_ctors and __wasm_call_dtors in Wizer init function and javy.invoke function in javy_core.wasm.

Why am I making this change?

These functions need to be called in non-main functions that are exported from Rust crates that are compiled to a Wasm bin for parts of the WASI context to be initialized properly. This isn't currently causing a problem but would block code that tries to read environment variables or use directory preopens from working properly.

Checklist

  • I've updated the relevant CHANGELOG files if necessary. Changes to javy-cli and javy-core do not require updating CHANGELOG files.
  • I've updated the relevant crate versions if necessary. Versioning policy for library crates
  • I've updated documentation including crate documentation if necessary.

@jeffcharles jeffcharles merged commit 3b02858 into main Sep 22, 2023
14 checks passed
@jeffcharles jeffcharles deleted the jc.add-wasm-ctor-calls-to-javy-core-exports branch September 22, 2023 20:25
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