graalvm

grounded_sage 2025-02-21T07:41:43.831679Z

Is there any prior art of using a GraalVM binary executable packaged up into a Rust application? I am assuming it’s doable just curious if anyone has done

souenzzo 2025-02-22T17:12:20.660609Z

I managed to find the doc https://github.com/babashka/sci/blob/master/doc/libsci.md Libsci compiles sci (a clojure package/funcion) into a shared library .so via GraalVM, that can be used from rust/cpp/any ffi lang My initial idea was that you could study how libsci is compiled and use as a reference to compile your own library into a shared lib But another path to make clojure works in your rust app is to import libsci itself, and than make libsci run your clojure core. IDK. Both paths seems to have pros and cons 🙂

souenzzo 2025-02-21T22:06:29.118289Z

libsci packs sci library into rust bindings https://github.com/babashka/sci/tree/master/libsci

souenzzo 2025-02-21T22:06:37.566089Z

(via graalvm)

grounded_sage 2025-02-22T01:00:37.966319Z

Interesting. It’s not super clear to me how it’s used from the code. @souenzzo

grounded_sage 2025-02-22T04:00:37.657479Z

I am guessing that it takes sci (clojure) from a separate file and executes it?

Ingy döt Net 2025-02-27T03:07:56.916079Z

https://yamlscript.org compiles to a shared library libyamlscript.so and publishes a crate that binds to it: https://crates.io/crates/yamlscript and does the same for https://yamlscript.org/doc/bindings/#currently-available-libraries