JMODs and Arm support
swpalmer at gmail.com
Tue Apr 30 15:41:39 UTC 2019
I noticed that there is a download on openjfx.io <http://openjfx.io/> for an 11.0.2 Arm SDK, but no JMOD download for Arm. Nor is there any 64-bit Arm download, making it a bit of an outlier since there are no 32-bit binaries for the other platforms. (The website should probably label this better.) Is there any particular reason that JMOD downloads are not provided for Arm? My build process is using JMODs to jlink a runtime and I now have a need to get this working on embedded systems, including aarch64. I noticed that Bellsoft does supply an armv7/8 SDK with JavaFX modules included, but only for 32-bit, the 64-bit version doesn’t include JavaFX.
The current practice of bundling the native libraries in the JAR files and extracting them at runtime seems to me to be a rather ugly hack - precisely the thing that JMOD addresses*. I also expect the process of extracting a native library at runtime could lead to problems with anti-malware tools. Is not the preferred mechanism to use link on a JMOD to produce a runtime with the native code in the proper place to begin with?
The Gradle scripts provided at openjfx.io <http://openjfx.io/> don’t support this model either.
I still can’t find any JMOD artifacts published to Maven Central. I asked about this before and there seemed to agreement that publishing the JMOD files as artifacts was a reasonable thing to do. I’m currently uploading them to our local Artifactory server to work around this.
*There is still an issue with the poor support for JMOD during development. You have to create a JRE outside of the JDK and wedge it in to your development process in order to debug, because JMOD isn’t supported at runtime. I’m not sure if there are any plans to improve that situation. For now I have ugly build scripts to use the .jar files for debugging and the JMODs for compiling and jlink.
On another note: Does the Arm version of OpenJFX support a desktop environment yet? Instead of forcing a fullscreen situation? I would like things such as Dialogs and FileChoosers to work on a Raspberry Pi setup.
More information about the openjfx-dev