When using the GluonFX plugins (for Maven and Gradle) in a JavaFX application, developers are leveraging Gluon Substrate which provides the way to create native images for Java and JavaFX projects that can target all platforms (desktop, mobile and embedded). If you are new to this, please have a look at our documentation on how to get started.
If you want to create a JavaFX application that should result in native applications for different platforms, you can easily get started by generating the skeleton for your project at start.gluon.io.
Under the hood, Gluon Substrate leverages the GraalVM project. Therefore, developers using Gluon Substrate must have a GraalVM bundle on their system. In order to simplify development, we create our own builds of GraalVM, with a strong focus on client applications, including JavaFX support. These Gluon builds of GraalVM are 100% based on the GraalVM master, but include a few changes required for JavaFX and Gluon Substrate, and have been fully tested by the Gluon engineers.
At Gluon, we keep tracking and testing the GraalVM official daily builds, so we can anticipate any breaking change and keep Gluon Substrate in sync.
With this release, we are adding support for JDK17 and JavaFX 17 while keeping the existing support for JDK11 and JavaFX 11. This ensures that Gluon JavaFX LTS customers, which get access to updated builds of JavaFX 11 and JavaFX 17, can get long-term supported native builds for their applications. Developers who want to use the latest JavaFX code can do this since Gluon Substrate already works with early-access builds of JavaFX 18.
The GluonFX plugins are updated for the new GraalVM versions, and native images can be created for all platforms to use either Java 11 or 17. Hence, it is up to the developer to select which version to use.
Support for the iOS Simulator!
One of the great additions in this Gluon build of GraalVM is support for the iOS simulator. This is now available in the GluonFX plugins version 1.0.12. Contrary to most other features, this iOS simulator support requires JDK17.
Go and grab the GraalVM build that better suits your project here: https://github.com/gluonhq/graal/releases, install it, and if you want to give it a quick test, bootstrap your project from start.gluon.io.
Or, if you build your project with GitHub actions, you can use the Gluon setup-graalvm action, that has been updated to select the JDK version, and defaults to JDK 17.