@tarsa thanks for the info. The first 3 links you provide I already had looked at. Your example however, I did not find, though I had searched (other threads also have JFX examples). But I have already set-up and used a Mill project much like your example. However, in my example I had to set the JVM arguments so:
JAVA_OPTS="--module-path=/usr/share/openjfx/lib --add-modules=javafx.controls,javafx.fxml,javafx.graphics,javafx.media,javafx.swing,javafx.web --add-reads=javafx.graphics=ALL-UNNAMED --add-opens=javafx.graphics/com.sun.glass.ui=ALL-UNNAMED --add-opens=javafx.controls/com.sun.javafx.charts=ALL-UNNAMED --add-opens=javafx.graphics/com.sun.javafx.iio=ALL-UNNAMED --add-opens=javafx.graphics/com.sun.javafx.iio.common=ALL-UNNAMED --add-opens=javafx.graphics/com.sun.javafx.css=ALL-UNNAMED --add-opens=javafx.graphics/com.sun.javafx.application=ALL-UNNAMED --add-opens=javafx.base/com.sun.javafx.runtime=ALL-UNNAMED"
I have 2 issues. First, you said:
but I had to add these --add-modules
in Mill. I need to check this again. Do you know if SBT does anything specific for this case?
The second is, I am assuming that according to your feedback I need only add the JDK library to the dependencies. If so, how do I configure this in SBT or any other build tool? Note that this is a module (not a jar) and I have a jmod
:
/usr/lib/jvm/java-11-openjdk-amd64/jmods/java.net.http.jmod
/usr/lib/jvm/java-11-openjdk-amd64/legal/java.net.http
/usr/lib/jvm/java-11-openjdk-amd64/legal/java.net.http/ASSEMBLY_EXCEPTION
I can list and extract its contents using jmod
. Looks like a jar, but I don’t think it is feasible to be use as a Jar (seen someone else attempt this).
Appreciate any help.
TIA