Just a quick report:
I thought that maybe with the 64bit build of SFOS on the Xperia 10 II the aarch64 support of graalvm is usable.
Aaand it is:
Howto:
- Download and un-tar the graalvm distribution following their install instructions.
- install
glibc-devel zlib-devel gcc
- compile sample java file (here: Run.java) with
<graalvm>/bin/javac Run.java
- test it with
<graalvm>/bin/java Run
- install native image with
<graalvm>/bin/gu install native-image
- create native image with
<graalvm>/bin/native-image Run
- wait
- execute with
./run
In my example the resulting image is 9.2mb.