Skip to content

Upgrade dune version to get WASM binary #7349

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

Merged
merged 9 commits into from
Mar 26, 2025

Conversation

cometkim
Copy link
Member

No description provided.

@cometkim cometkim requested review from cknitt and tsnobip March 18, 2025 14:09
Copy link
Member

@tsnobip tsnobip left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good to me!

@cometkim cometkim force-pushed the dune-wasm branch 3 times, most recently from 251dd7b to f376368 Compare March 24, 2025 20:26
@cometkim cometkim marked this pull request as ready for review March 24, 2025 21:19
@cometkim cometkim force-pushed the dune-wasm branch 2 times, most recently from 277f7f6 to 9c49689 Compare March 26, 2025 11:32
@cometkim cometkim force-pushed the dune-wasm branch 2 times, most recently from a544ca7 to 601d2f6 Compare March 26, 2025 12:00
@cometkim
Copy link
Member Author

The WASM compiler failed to be installed on Windows.

However, we don't perform JSOO tests on Windows. So I think it's better to skip

Since conditional dependency is not supported in the dune syntax, we had to move the dependency management to the opam template. This is also the method that the dune project uses itself.

@cometkim cometkim requested a review from cknitt March 26, 2025 13:06
Copy link
Member

@cknitt cknitt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work! Thanks a lot!


if (process.platform !== "win32") {
child_process.execSync(`strip ${dest}`);
let mode = 0o755;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are the permission-related changes required now?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They don't give write permission anymore. binaries are r+x.

The script is to grant required permissions before the task and to revoke them after it is completed.

@cometkim cometkim merged commit 3f06468 into rescript-lang:master Mar 26, 2025
20 checks passed
@cometkim cometkim deleted the dune-wasm branch March 26, 2025 13:30
fhammerschmidt pushed a commit that referenced this pull request Apr 4, 2025
* upgrade dune version to get WASM build

* suppress warnings in corrected way

* fix permission issues

* format

* install js_of_ocaml-ppx

* fix

* fix playground test

* manage dependency list in opam template

* fix opam cache key to use opam
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.

3 participants