Hi all! I’ve been playing around a bit with Quil and Processing, and I wanted to share some stuff I made with some friends. I thought that compiling to a static executable using GraalVM might be a good way to do that. However when I run lein native-image, I get the following error. Note that I had to skip the --initialize-at-build-time flag because otherwise it tries to start my sketches. My code is here: https://github.com/maxrothman/playing-with-processing, and I’m using the
native-image lein plugin.
Any ideas? I took a look through https://github.com/lread/clj-graal-docs but I didn’t see anything that seemed related. I’m completely new to graalvm and fairly new to Java, so sorry if this has been asked before
Also, make sure you're using 1.10.2-alpha4
Thanks for the suggestion, @borkdude! I am using clojure 1.10.2-alpha4. I can’t use the fix you linked to though because Processing is only compatible with Java 8
@max.r.rothman Which version of GraalVM are you using to compile then?
@max.r.rothman Have you tried
I get this error:
@max.r.rothman It seems like you're getting the same error as https://clojurians.slack.com/archives/CAJN79WNT/p1607554227199300. I don't know how y'all are compiling your code, so unless you post a complete repro + build scripts online, I don't have much more to say.
My code is at https://github.com/maxrothman/playing-with-processing, and I’m building using
lein native-image (via the https://github.com/taylorwood/lein-native-image plugin)
Thanks for the help so far!
I recommend just writing a shell script to compile. It's hard to see what's wrong when using wrappers.
Take a look at the hello world examples how that is done.