You are not logged in.
Pages: 1
I just installed pdfsam along with the javafx and java-9 dependencies. However as soon as pdfsam tries to draw its window the program crashes. From the stacktrace it looks like javafx just isn't linked right but I don't know enough about how java works to link it
I've set my env so I know it's using the right java
JAVA_HOME=/usr/lib/jvm/java-9-openjdkAnd here's the stacktrace
Exception in thread "main" java.lang.NoClassDefFoundError: javafx/scene/layout/HBox
at java.base/java.lang.ClassLoader.defineClass1(Native Method)
at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1007)
at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:174)
at java.base/jdk.internal.loader.BuiltinClassLoader.defineClass(BuiltinClassLoader.java:801)
at java.base/jdk.internal.loader.BuiltinClassLoader.findClassOnClassPathOrNull(BuiltinClassLoader.java:699)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClassOrNull(BuiltinClassLoader.java:622)
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:580)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:185)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:496)
at org.pdfsam.community.App.main(App.java:34)
Caused by: java.lang.ClassNotFoundException: javafx.scene.layout.HBox
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:582)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:185)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:496)
... 10 more
Offline
You usually don't have to set your env manually, and that might be the problem, just set the correct environment using archlinux-java FWIW depending on what the program depends on you might be better off with openjdk 8 in general, since 9 did contain some changes that might render certain programs unbootable. I'm not entirely sure if java 9 would need it's own openjfx package or if it can use the libraries from the java 8 release.
If your end goal is to simply run the program using java 8 will avoid a few potential gotchas anyway.
Last edited by V1del (2018-01-01 21:49:39)
Offline
Wow, switching to java 8 did help. Thanks!
Offline
...switching to java 8 did help.
Hi ripread, there's also the Wiki option if you want to keep your default environment java9, although may have to be aware of it if/when pdfsam updates to java9. I put the script in /usr/bin, called it "pdfsam_run" and then changed the pdfsam launcher in /usr/share/applications to it.
∞ hard times make the strong, the strong make good times, good times make the weak, the weak make hard times ∞
Offline
FWIW for java 9 we indeed do not have the openjfx libraries currently: https://bugs.archlinux.org/task/55776
Please mark as [SOLVED] by editing the title of your first post
Offline
Pages: 1