graalvm

Discuss GraalVM related topics. Use clojure 1.10.2 or newer for all new projects. Contribute to https://github.com/clj-easy/graal-docs and https://github.com/BrunoBonacci/graalvm-clojure. GraalVM slack: https://www.graalvm.org/slack-invitation/.
2020-05-18T07:51:44.264100Z

@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

avi 2020-05-18T20:09:40.266Z

👋 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…

littleli 2020-05-18T20:32:57.267800Z

you're on MacOS, so why it tries to use linux archives?

littleli 2020-05-18T20:35:04.268500Z

what's result of this:

gu list

littleli 2020-05-18T20:37:20.269500Z

Reason for above is that gnu-tar is incompatible with tar on MacOS. So I would suggest you check you downloaded proper distribution.

avi 2020-05-18T20:45:50.272400Z

> 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/jar

littleli 2020-05-18T21:21:28.273600Z

I 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 😞

👍 1
borkdude 2020-05-18T21:29:00.273900Z

There is a similar issue here: https://github.com/oracle/graal/issues/1974

avi 2020-05-18T21:57:24.275Z

Yeah but it’s closed with no useful info… I guess I’ll open a new issue.

avi 2020-05-18T22:33:27.275400Z

I’ve put together a basic reproduction here: https://github.com/FundingCircle/repro-graalvm-mac-issue/runs/687035110