java -jar Behinder.jar
8月 30, 2023 12:59:33 下午 com.sun.javafx.application.PlatformImpl startup
警告: Unsupported JavaFX configuration: classes were loaded from 'unnamed module @22de69b2'
Loading library prism_es2 from resource failed: java.lang.UnsatisfiedLinkError: Can't load library: /Users/xxxxxx/.openjfx/cache/19+11/aarch64/libprism_es2.dylib
java.lang.UnsatisfiedLinkError: Can't load library: /Users/xxxxx/.openjfx/cache/19+11/aarch64/libprism_es2.dylib
at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2398)
at java.base/java.lang.Runtime.load0(Runtime.java:785)
at java.base/java.lang.System.load(System.java:1979)
at com.sun.glass.utils.NativeLibLoader.installLibraryFromResource(NativeLibLoader.java:217)
at com.sun.glass.utils.NativeLibLoader.loadLibraryFromResource(NativeLibLoader.java:197)
at com.sun.glass.utils.NativeLibLoader.loadLibraryInternal(NativeLibLoader.java:138)
at com.sun.glass.utils.NativeLibLoader.loadLibrary(NativeLibLoader.java:54)
at com.sun.prism.es2.ES2Pipeline.lambda$static$0(ES2Pipeline.java:63)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:318)
at com.sun.prism.es2.ES2Pipeline.<clinit>(ES2Pipeline.java:52)
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Class.java:383)
at java.base/java.lang.Class.forName(Class.java:376)
at com.sun.prism.GraphicsPipeline.createPipeline(GraphicsPipeline.java:218)
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.init(QuantumRenderer.java:92)
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:125)
at java.base/java.lang.Thread.run(Thread.java:833)
Loading library prism_sw from resource failed: java.lang.UnsatisfiedLinkError: Can't load library: /Users/xxxxx/.openjfx/cache/19+11/aarch64/libprism_sw.dylib
java.lang.UnsatisfiedLinkError: Can't load library: /Users/xxxx/.openjfx/cache/19+11/aarch64/libprism_sw.dylib
at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2398)
at java.base/java.lang.Runtime.load0(Runtime.java:785)
at java.base/java.lang.System.load(System.java:1979)
at com.sun.glass.utils.NativeLibLoader.installLibraryFromResource(NativeLibLoader.java:217)
at com.sun.glass.utils.NativeLibLoader.loadLibraryFromResource(NativeLibLoader.java:197)
at com.sun.glass.utils.NativeLibLoader.loadLibraryInternal(NativeLibLoader.java:138)
at com.sun.glass.utils.NativeLibLoader.loadLibrary(NativeLibLoader.java:54)
at com.sun.prism.sw.SWPipeline.lambda$static$0(SWPipeline.java:43)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:318)
at com.sun.prism.sw.SWPipeline.<clinit>(SWPipeline.java:42)
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Class.java:383)
at java.base/java.lang.Class.forName(Class.java:376)
at com.sun.prism.GraphicsPipeline.createPipeline(GraphicsPipeline.java:218)
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.init(QuantumRenderer.java:92)
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:125)
at java.base/java.lang.Thread.run(Thread.java:833)
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:283)
at com.sun.javafx.tk.quantum.QuantumToolkit.init(QuantumToolkit.java:253)
at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:268)
at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:291)
at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:163)
at com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:659)
at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:679)
at com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:196)
at java.base/java.lang.Thread.run(Thread.java:833)
Caused by: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.init(QuantumRenderer.java:95)
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:125)
... 1 more
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:283)
at com.sun.javafx.tk.quantum.QuantumToolkit.init(QuantumToolkit.java:253)
at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:268)
at javafx.stage.Screen.<clinit>(Screen.java:74)
at javafx.stage.Window.<init>(Window.java:1504)
at javafx.stage.Stage.<init>(Stage.java:256)
at javafx.stage.Stage.<init>(Stage.java:244)
at javafx.scene.control.HeavyweightDialog$1.<init>(HeavyweightDialog.java:52)
at javafx.scene.control.HeavyweightDialog.<init>(HeavyweightDialog.java:52)
at javafx.scene.control.Dialog.<init>(Dialog.java:252)
at javafx.scene.control.Alert.<init>(Alert.java:247)
at javafx.scene.control.Alert.<init>(Alert.java:222)
at net.rebeyond.behinder.utils.Utils.getAlert(Utils.java:85)
at net.rebeyond.behinder.utils.Utils.showErrorMessage(Utils.java:1341)
at net.rebeyond.behinder.ui.Main.main(Main.java:57)
at net.rebeyond.behinder.ui.Launcher.main(Launcher.java:7)
Caused by: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.init(QuantumRenderer.java:95)
at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:125)
at java.base/java.lang.Thread.run(Thread.java:833)
java.lang.ExceptionInInitializerError
at javafx.stage.Window.<init>(Window.java:1504)
at javafx.stage.Stage.<init>(Stage.java:256)
at javafx.stage.Stage.<init>(Stage.java:244)
at javafx.scene.control.HeavyweightDialog$1.<init>(HeavyweightDialog.java:52)
at javafx.scene.control.HeavyweightDialog.<init>(HeavyweightDialog.java:52)
at javafx.scene.control.Dialog.<init>(Dialog.java:252)
at javafx.scene.control.Alert.<init>(Alert.java:247)
at javafx.scene.control.Alert.<init>(Alert.java:222)
at net.rebeyond.behinder.utils.Utils.getAlert(Utils.java:85)
at net.rebeyond.behinder.utils.Utils.showErrorMessage(Utils.java:1341)
at net.rebeyond.behinder.ui.Main.main(Main.java:57)
at net.rebeyond.behinder.ui.Launcher.main(Launcher.java:7)
Caused by: java.lang.RuntimeException: No toolkit found
at com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:280)
at javafx.stage.Screen.<clinit>(Screen.java:74)
... 12 more
本次集成的java fx的版本不兼容M1架构
启动参数加入javafx javafx-sdk-17.0.8,才可以运行
java --module-path /Users/xxxxx/Library/Java/Extensions/javafx-sdk-17.0.8/lib --add-modules=javafx.base,javafx.controls,javafx.fxml,javafx.graphics,javafx.media,javafx.swing,javafx.web -jar Behinder.jar
是否考虑M1架构的兼容?