Goldleaf
Goldleaf copied to clipboard
Quark and Linux issues
[Quark] Error: JavaFX runtime components are missing
Bug description
When attempting to run the jar with an OpenJDK version of java or a more recent version of Oracle Java the following error occurs:
Error: JavaFX runtime components are missing, and are required to run this application
JavaFX is no longer bundled with JDK/JRE as of Java 11 and Jars are not intended to be ran alone, instead the convention is to use a launcher.
Your setup
-
Console firmware: 9.0.0
-
CFW with version: Atmosphere 0.9.4
-
Goldleaf version: 0.7.1
-
Goldtree version: Quark-Release1
Bug reproduction
- Install latest JRE/JDK
- Download
Quark.jar - Launch
Quark.jareither by double clicking or runningjava -jar Quark.jarin terminal/cmd - Fails to launch, if launched by terminal greeted with following:
Error: JavaFX runtime components are missing, and are required to run this application
Additional information
Solution might be to provide a launcher that launches the jar with bundled javafx modules. Java8 is archived on Oracle's website so it's sort of a pain to install, building with a more recent JDK might be preferred.
Same here. Java8 with OpenJFX almost works but the window is screwed up

Java 11 and 12 with OpenJFX error out with the missing.
https://github.com/droidman/Goldleaf you can get it further with my hacks but it's not fully working on Linux yet. You can't select folders to share yet but you can still browse "/" and select individual files.
It also fails to detect connection when you open quark with java -jar, old exe works just fine
@aria0012 I’m not sure that’s related to this issue. Make sure to open your own issue for other bugs. This is specifically about JavaFX.
Solution should be to bundle JavaFX as other similar apps do.
@A6GibKm JavaFX is bundled. @aria0012 That's unrelated and you need either a udev rule or run as root on linux.
Use Java SE 8 if you want quark to run on Linux for now.
It is bundled? It does not work as soon as I remove openjfx from my machine.
0.7.2 crashes even weirder
[parker@stealth Videos]$ java -jar Quark.jar
Sep 19, 2019 4:17:02 PM javafx.fxml.FXMLLoader$ValueElement processValue
WARNING: Loading FXML document with JavaFX API of version 11.0.1 by JavaFX runtime of version 11
Exception in Application start method
Exception in thread "main" java.lang.RuntimeException: Exception in Application start method
at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:900)
at com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:195)
at java.base/java.lang.Thread.run(Thread.java:835)
Caused by: java.lang.NoClassDefFoundError: com/sun/javafx/css/converters/PaintConverter
at com.jfoenix.controls.JFXTextArea$StyleableProperties.<clinit>(JFXTextArea.java:221)
at com.jfoenix.controls.JFXTextArea.<init>(JFXTextArea.java:145)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:500)
at java.base/java.lang.reflect.ReflectAccess.newInstance(ReflectAccess.java:166)
at java.base/jdk.internal.reflect.ReflectionFactory.newInstance(ReflectionFactory.java:404)
at java.base/java.lang.Class.newInstance(Class.java:590)
at javafx.fxml.FXMLLoader$InstanceDeclarationElement.constructValue(FXMLLoader.java:1019)
at javafx.fxml.FXMLLoader$ValueElement.processStartElement(FXMLLoader.java:754)
at javafx.fxml.FXMLLoader.processStartElement(FXMLLoader.java:2722)
at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2552)
at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2466)
at javafx.fxml.FXMLLoader.load(FXMLLoader.java:2435)
at xorTroll.goldleaf.quark.ui.MainApplication.start(MainApplication.java:103)
at com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$9(LauncherImpl.java:846)
at com.sun.javafx.application.PlatformImpl.lambda$runAndWait$12(PlatformImpl.java:455)
at com.sun.javafx.application.PlatformImpl.lambda$runLater$10(PlatformImpl.java:428)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:389)
at com.sun.javafx.application.PlatformImpl.lambda$runLater$11(PlatformImpl.java:427)
at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:96)
at com.sun.glass.ui.gtk.GtkApplication._runLoop(Native Method)
at com.sun.glass.ui.gtk.GtkApplication.lambda$runLoop$11(GtkApplication.java:277)
... 1 more
Caused by: java.lang.ClassNotFoundException: com.sun.javafx.css.converters.PaintConverter
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:583)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
... 25 more
OpenJRE 12 with OpenJFX
Same, it was working last time, now I get
Exception in thread "main" java.lang.UnsupportedClassVersionError: javafx/application/Application has been compiled by a more recent version of the Java Runtime (class file version 54.0), this version of the Java Runtime only recognizes class file versions up to 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:763)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:468)
at java.net.URLClassLoader.access$100(URLClassLoader.java:74)
at java.net.URLClassLoader$1.run(URLClassLoader.java:369)
at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:763)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:468)
at java.net.URLClassLoader.access$100(URLClassLoader.java:74)
at java.net.URLClassLoader$1.run(URLClassLoader.java:369)
at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at xorTroll.goldleaf.quark.Main.main(Main.java:9)
with java-1.8.0-openjdk and with java-12-openjdk I get:
(java:7578): Gdk-CRITICAL **: 18:37:32.589: gdk_x11_display_set_window_scale: assertion 'GDK_IS_X11_DISPLAY (display)' failed
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007f09510d256a, pid=7578, tid=7604
#
# JRE version: OpenJDK Runtime Environment (12.0.2+9) (build 12.0.2+9)
# Java VM: OpenJDK 64-Bit Server VM (12.0.2+9, mixed mode, sharing, tiered, compressed oops, g1 gc, linux-amd64)
# Problematic frame:
# C [libX11.so.6+0x3156a]
#
# Core dump will be written. Default location: Core dumps may be processed with "/usr/lib/systemd/systemd-coredump %P %u %g %s %t %c %h %e" (or dumping to /home/msandoval/.opt/Switch/core.7578)
#
# An error report file with more information is saved as:
# /home/msandoval/.opt/Switch/hs_err_pid7578.log
#
# If you would like to submit a bug report, please visit:
# http://bugreport.java.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#
[1] 7578 abort (core dumped) java -jar Quark.jar
If I disable openjfx the core is dumped in both cases.
For some reason I had disabled a component of openjfx so ignore the logs above, I still think that JafaFX should be bundled as it is harder to get with newer java versions. The jar is working with java-1.8.0-openjdk in fedora 30. I still have to test if it connects with goldleaf 0.7.2.
Just to add, @XorTroll the title you've set is slightly misleading. OpenJDK is not linux-specific, this issue occurs on MacOS as well. OpenJDK is a decision some of us make deliberately. "Install Oracle Java" is not an ideal solution, as you can imagine.
Fails to launch on Ubuntu 18.04 too
WARNING: Loading FXML document with JavaFX API of version 11.0.1 by JavaFX runtime of version 11
Exception in Application start method
Exception in thread "main" java.lang.RuntimeException: Exception in Application start method
at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:900)
at com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:195)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.NoClassDefFoundError: com/sun/javafx/css/converters/PaintConverter
at com.jfoenix.controls.JFXTextArea$StyleableProperties.
Same issues on windows with OpenJDK 8, 10 and 12
Yeah I’m not sure why this is being written off as a Linux issue. People use OpenJDK on every platform, and given this software is open source it shouldn’t rely on Oracles JDK.
Especially since Oracle JDK 8 sucks to download now.
My solution was compiling my own Quark.jar from master with openjdk12 and openjfx12. You can download it here for use at your own risk: https://pbb.lc/public/Quark.jar Good luck!
Could you provide detailed info on how you did this? It would be also helpful to know whether this runs with oracle's, this could help the maintainers to compile Quark with openjdk12.
Could you provide detailed info on how you did this? It would be also helpful to know whether this runs with oracle's, this could help the maintainers to compile Quark with openjdk12.
I just cloned the repo and ran build.sh in Quark/. I did not make any changes to the code.
Finally found a work around on Ubuntu 18.04 that fixes the same "Error: JavaFX" issue.
Ended up manually installing Oracle JRE/JDK 8.0.221 and adding it to the 'update-alternatives' program for quick selection between Java versions.
To follow along:
- First, Download the file: 'jdk-8u221-linux-x64.tar.gz' ...and, yes, for this link you'll need a free Oracle account.
Found at: https://www.oracle.com/technetwork/java/javase/downloads/java-archive-javase8u211-later-5573849.html
-
In [terminal], navigate to 'Downloads' directory- then run:
tar zxf "jdk-8u221-linux-x64.tar.gz" -
We'll move the extracted folder to shared 'jvm' directory. Run:
sudo mv jdk1.8.0_221/ /usr/lib/jvm/ -
Next, manually add a record for "OracleJDK 8.0.221" into the [update-alternatives] program. Run:
sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk1.8.0_221/bin/java 1082 -
Get current Java version. This is so you know which version to switch back to when finished. Run:
java --version
I see:
java version "13.0.1" 2019-10-15 Java(TM) SE Runtime Environment (build 13.0.1+9) Java HotSpot(TM) 64-Bit Server VM (build 13.0.1+9, mixed mode, sharing)
- Switch java versions using:
sudo update-alternatives --config java
You'll be greeted with something similar to (but easier to read):
There are 4 choices for the alternative java (providing /usr/bin/java).
Selection____Path__________________________Priority___Status
------------------------------------------------------------
0 /usr/lib/jvm/java-13-oracle/bin/java 1091 auto mode
* 1 /usr/lib/jvm/java-13-oracle/bin/java 1091 manual mode
2 /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java 1081 manual mode
3 /usr/lib/jvm/jdk1.8.0_221/bin/java 1082 manual mode
Press <enter> to keep the current choice[*], or type selection number:
For me, I entered [3] to change to "jdk1.8.0_221".
- Test the change:
java --version
Which now shows:
java version "1.8.0_221" Java(TM) SE Runtime Environment (build 1.8.0_221-b11) Java HotSpot(TM) 64-Bit Server VM (build 25.221-b11, mixed mode)`
- Finally, go execute 'Quark.jar' (where ever you saved it).
java -jar Quark.jar
That works for me.
Best of luck!!
References:
- Thomas Bratt's script response to: https://stackoverflow.com/questions/25729592/how-to-install-jdk-8-in-ubuntu-12-04-using-tar-gz-file#25731092
Note:
-
This can be used as an outline for the steps to manually install other versions of Java too (ex. OracleJRE-8.221). Code the records accordingly to the version you use.
-
After step 4, I found it's possible to use [galternatives] to select installed versions of Java.
https://askubuntu.com/questions/159575/how-do-i-make-java-default-to-a-manually-installed-jre-jdk#159585
However, I was not able to install alternative java versions from within [galternatives]. Selection only for me.
I hope this helps!
@Wilaemus that is a known workaround. Installing Oracle JDK/JRE is not an acceptable solution, however.
Can confirm that building Quark from source works. I just needed maven on my path and run the build.sh. Tested this with jdk-11.0.4.11-openj9 and javafx-sdk-11.0.2.
Tested on Ubuntu 19.10 and Goldleaf 0.7.3 on Nintendo Switch Firmware 6.2.0:
sudo apt install maven
git clone https://github.com/XorTroll/Goldleaf.git
cd Goldleaf/Quark
chmod +x build.sh
sh build.sh
cd target
sudo java -jar Quark.jar
I am using OpenJDK 11
It seems that #428 fixed it (the ClassNotFoundException is caused by a breaking change in JavaFX 9), hence why building from master works.
I have tested with the following on my system (Archlinux)
- java-10-openjdk
- java-11-openjdk
- java-13-jdk
- java-13-openjdk
- java-8-jdk
- java-8-openjdk/jre
- java-9-jdk
only with java-8-jdk I was able to run and properly work on my system
Oof. I am not able to build latest quark 0.3.0, anyone else with this issue?
Specs:
- Fedora Silverblue 31
- java-11-openjdk
Here is the process to install run the latest Quark in Linux (Tested in Fedora using Quark 0.8)
- Download Quark
- Install the latest openjdk
sudo dnf install java-latest-openjdk - Change your default java runtime
sudo alternatives --config java - Select the latest java by typing the number (Mine was number 2)
- Run Quark by opening a terminal in the directory that quark is located
java -jar Quark.jar
Here is the process to install run the latest Quark in Linux (Tested in Fedora using Quark 0.8)
1. Download Quark 2. Install the latest openjdk `sudo dnf install java-latest-openjdk` 3. Change your default java runtime `sudo alternatives --config java` 4. Select the latest java by typing the number (Mine was number 2) 5. Run Quark by opening a terminal in the directory that quark is located `java -jar Quark.jar`
Since fedora uses wayland by default you have to run it as
GDK_BACKEND=x11 java -jar Quark.jar
But for some reason, Quark 0.3 uses all my cpu, to the point where my machine freezes.
Is there a reason you cannot run the latest 0.8?
Sent from ProtonMail Mobile
On Thu, Feb 6, 2020 at 7:50 AM, Maximiliano [email protected] wrote:
Here is the process to install run the latest Quark in Linux (Tested in Fedora using Quark 0.8)
Download Quark
Install the latest openjdk
sudo dnf install java-latest-openjdkChange your default java runtime
sudo alternatives --config javaSelect the latest java by typing the number (Mine was number 2)
Run Quark by opening a terminal in the directory that quark is located
java -jar Quark.jarSince fedora is uses wayland by default you have to run it as GDK_BACKEND=x11 java -jar Quark.jar But for some reason, Quark 0.3 uses all my cpu, to the point where my machine freezes.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
The latest is actually 0.3 (which corresponds to goldleaf 0.8). I can run 0.2 just fine.
Same here. Java8 with OpenJFX almost works but the window is screwed up
Java 11 and 12 with OpenJFX error out with the missing.
I have exactly the same issue with broken GUI window on Manjaro with KDE. Cannot be resized nor maximized. Even after building Quark myself, following instruction from here: https://github.com/XorTroll/Goldleaf/blob/master/docs/QUARK_LINUX.md
@parkerlreed Have you managed to solve it somehow?
@luk1505 what Quark version are you trying?
@A6GibKm from newest Goldleaf release 0.8 (30 Dec 2019). Quark version number is not specified there.
I also tried Quark from older release 0.7.3, but I'm getting JavaFX errors (mentioned in this thread earlier by other people).
I had the same issue today, also Manjaro KDE.
It seems to be an issue with KDE specifically, or maybe Manjaro + KDE. I installed XFCE as second DE and Quark is working there fine, no issues. Also tested on latest Ubuntu with Gnome.
Can confirm, it' an issue that only happens in KDE. Needs to be fixed on Quark, not KDE though
I think this issue should be closed since it already works under KDE. The only thing is to add a udev rule if you don't want to run it as root (this applies to all linux systems)
Still happening for me with: Java 8 macOS 11.4 0.9 (+ Quark 0.4)
Any way to get this to work without compiling from source?
openjdk version "11.0.11" 2021-04-20
OpenJDK Runtime Environment AdoptOpenJDK-11.0.11+9 (build 11.0.11+9)
OpenJDK 64-Bit Server VM AdoptOpenJDK-11.0.11+9 (build 11.0.11+9, mixed mode)
WARNING: Loading FXML document with JavaFX API of version 11.0.1 by JavaFX runtime of version 11
Exception in Application start method
Exception in thread "main" java.lang.RuntimeException: Exception in Application start method