truffleruby
truffleruby copied to clipboard
WASI p1 support
With SubstrateVM now compiling to WASI p1 with --tool:svm-wasm, next is TruffleRuby running on WASM.
I tried running the following with --tool:svm-wasm, but it looks like the --language:ruby flag was removed from the native-image tool.
https://github.com/oracle/truffleruby/blob/d583795f22941cfac6342e9a226acf5f0f61e5a9/doc/contributor/native-image.md?plain=1#L86
Any insight into hacking the mx build to target wasm would be very helpful.
See: https://2025.wasm.io/sessions/the-future-of-write-once-run-anywhere-from-java-to-webassembly/ See: #82
Right, that part is outdated, --language:ruby is a legacy macro and that's gone now.
These days, you would get the jars from Maven for org.graalvm.polyglot:ruby, and either use the Native Image Maven/Gradle plugin or get the full classpath of the dependencies via something like mvn dependency:build-classpath.