bigdata-file-viewer icon indicating copy to clipboard operation
bigdata-file-viewer copied to clipboard

JavaFX Problem running on macOS Monterey with OpenJDK

Open rberger opened this issue 3 years ago • 3 comments

When I try to run BigdataFileViewer-1.3-SNAPSHOT-jar-with-dependencies.jar I get the error:

java -jar Downloads/BigdataFileViewer-1.3-SNAPSHOT-jar-with-dependencies.jar
Graphics Device initialization failed for :  es2, sw
Error initializing QuantumRenderer: no suitable pipeline found
java.lang.RuntimeException: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found
	at com.sun.javafx.tk.quantum.QuantumRenderer.getInstance(QuantumRenderer.java:280)
...

And with BigdataFileViewer-1.1.1-SNAPSHOT-jar-with-dependencies.jar I get:

 java -jar Downloads/BigdataFileViewer-1.1.1-SNAPSHOT-jar-with-dependencies.jar
Exception in thread "main" java.lang.NoClassDefFoundError: javafx/application/Application
	at java.base/java.lang.ClassLoader.defineClass1(Native Method)
	at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1012)
...

Running macOS Monterey on an intel iMac 2020 and tried with openjdk 11 and 17

I believe the issue may be that those distributions don't include JavaFX libraries? I don't know how to correct for that though.

rberger avatar Jan 17 '22 23:01 rberger

Same here. Exactly same errors for both libs.

I tried on macOS Catalina MacBook Pro (16-inch, 2019), Intel Core i7 on JDK 8 and 11

Also Installed jfx libs for jdk11 via brew as suggested below
https://stackoverflow.com/questions/61050869/installing-javafx-15-on-mac

But I get a new error as below

❯ java -jar BigdataFileViewer-1.3-SNAPSHOT-jar-with-dependencies.jar Graphics Device initialization failed for : es2, sw Error initializing QuantumRenderer: no suitable pipeline found java.lang.RuntimeException: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found at com.sun.javafx.tk.quantum.QuantumRenderer.getInstance(QuantumRenderer.java:280) at com.sun.javafx.tk.quantum.QuantumToolkit.init(QuantumToolkit.java:222) at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:260) at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:267) at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:158) at com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:658) at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:678) at com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:195) at java.base/java.lang.Thread.run(Thread.java:829) Caused by: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.init(QuantumRenderer.java:94) at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:124) ... 1 more Exception in thread "main" java.lang.RuntimeException: No toolkit found at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:272) at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:267) at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:158) at com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:658) at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:678) at com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:195)

jayaku avatar Jan 24 '22 06:01 jayaku

Also having the same issue

a-agmon avatar Mar 03 '22 11:03 a-agmon

I ran into the same issue. Resolved as follows

brew tap bell-sw/liberica
brew install --cask bell-sw/liberica/liberica-jdk18-full

java -jar BigdataFileViewer-1.3-SNAPSHOT-jar-with-dependencies.jar

sherif-fanous avatar Apr 25 '22 18:04 sherif-fanous

@rberger Yes you're right, Graphics Device initialization failed for : es2, sw shows that the library javafx is missing. Please make sure that you have javafx installed on your machine. As for the issue you met with BigdataFileViewer-1.1.1-SNAPSHOT-jar-with-dependencies.jar, it's a known issue and has been fixed by later version.

Eugene-Mark avatar Oct 23 '22 16:10 Eugene-Mark

@rberger @jayaku @a-agmon The issue you met is because the lacking of javafx on you local env, please try install javafx firstly. At the same time, the process to make sure javafx installed correctly might be a little annoying. Based on that, I'm considering release another version of BDF without the dependency to javafx. Thanks for your comment here.

Eugene-Mark avatar Oct 23 '22 16:10 Eugene-Mark