by packetlost · 3y ago · 0 comments
Alternative is to compile your Clj uberjar using GraalVM. Here's a project to document how to do that and which common libraries are compilable:
1. use vcvars64.bat, usually in ...\Community\Common7\Tools\vcvars64.bat or ...\Enterprise\VC\Auxiliary\Build\vcvars64.bat
2. lein uberjar
3. Setup GraalVM: set JAVA_HOME=C:\Program Files\GraalVM\graalvm-ce-java17-22.3.0
4. native-image --no-fallback -jar target\default+uberjar\clojuresque-0.1.0-SNAPSHOT-standalone.jar
(you have to tweak with the paths above, depending on your system.
The resulting executable isn't small, but it starts quickly and doesn't depend on anything on the system other than MS C-runtime redistributable.
Clojure like syntax, Rust like internals.