@nate I have extracted the parts that do work with Graalvm, but it’s not the same experience https://github.com/AdGoji/aws-api/blob/master/dev/examples.clj
👋 has anyone ever seen this?
Error: Invalid or corrupt jarfile /Users/avi.flax/.m2/repository/org/graalvm/truffle/truffle-nfi-native-linux-amd64/19.3.1/truffle-nfi-native-linux-amd64-19.3.1.tar.gz
Caused by: java.util.zip.ZipException: zip END header not found
com.oracle.svm.driver.NativeImage$NativeImageError: Invalid or corrupt jarfile /Users/avi.flax/.m2/repository/org/graalvm/truffle/truffle-nfi-native-linux-amd64/19.3.1/truffle-nfi-native-linux-amd64-19.3.1.tar.gz
When attempting to compile a native image on MacOS, using borkdude/clj-reflector-graal-java11-fix
? He’s been helping me in DMs, I tried both 19.3.1 and 19.3.2, tried nuking my .m2
, but no luck so far. Just thought I’d check…you're on MacOS, so why it tries to use linux archives?
what's result of this:
gu list
Reason for above is that gnu-tar
is incompatible with tar
on MacOS. So I would suggest you check you downloaded proper distribution.
> you’re on MacOS, so why it tries to use linux archives? Exactly‽ > what’s result of this…
$ gu list
ComponentId Version Component name Origin
--------------------------------------------------------------------------------
graalvm 19.3.2 GraalVM Core
native-image 19.3.2 Native Image <http://github.com|github.com>
> Reason for above is that gnu-tar is incompatible with tar on MacOS. So I would suggest you check you downloaded proper distribution.
Well, that file, truffle-nfi-native-linux-amd64-19.3.1.tar.gz
(which oddly doesn’t end with .jar
) was brought in via borkdude/clj-reflector-graal-java11-fix 0.0.1-graalvm-19.3.2
which depends on org.graalvm.nativeimage/svm 19.3.2
which depends on org.graalvm.nativeimage/svm-hosted-native-linux-amd64
amongst many other similar dependencies such as svm-hosted-native-darwin-amd64
(and that pom.xml
does specify that those dependencies are in tar.gz
files, so I guess that part is kosher)
https://search.maven.org/artifact/org.graalvm.nativeimage/svm/19.3.2/jarI believe it doesn't end with .jar because it contains prebuild binaries for each platform. The question is why does it pick the wrong one 😞
There is a similar issue here: https://github.com/oracle/graal/issues/1974
Yeah but it’s closed with no useful info… I guess I’ll open a new issue.
I’ve put together a basic reproduction here: https://github.com/FundingCircle/repro-graalvm-mac-issue/runs/687035110