Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jstock-1.0.7.47-bin, jdk1.8.0_271-arm32-vfp-hflt, java.lang.NoClassDefFoundError: org/jdesktop/jxlayer/JXLayer #164

Open
elizabethexpialadocious opened this issue Feb 17, 2021 · 0 comments

Comments

@elizabethexpialadocious

hi, I received the error:

Error: A JNI error has occurred, please check your installation and try again
Exception in thread "main" java.lang.NoClassDefFoundError: org/jdesktop/jxlayer/JXLayer
	at java.lang.Class.getDeclaredMethods0(Native Method)
	at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)
	at java.lang.Class.privateGetMethodRecursive(Class.java:3048)
	at java.lang.Class.getMethod0(Class.java:3018)
	at java.lang.Class.getMethod(Class.java:1784)
	at sun.launcher.LauncherHelper.validateMainClass(LauncherHelper.java:650)
	at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:632)
Caused by: java.lang.ClassNotFoundException: org.jdesktop.jxlayer.JXLayer
	at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:355)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:351)

upon starting './jstock.sh' using jstock-1.0.7.47-bin with jdk1.8.0_271-arm32-vfp-hflt on raspberry pi. However, creating a directory in the default jstock folder and copying all the*.jar files thereto remedied the issue. e.g.

cd jstock-1.0.7.47-bin
mkdir lib
cp *.jar lib

I also get 'Unrecognized option: --module-path' unless I comment out the _JAVAFXOPTIONS stuff:

_JAVAFXPATH="/usr/share/openjfx/lib"
if [[ (-d "$_JAVAFXPATH") && (-f "$_JAVAFXPATH/javafx.base.jar") ]] ; then
#   _JAVAFXOPTIONS="--module-path $_JAVAFXPATH --add-modules=javafx.base,javafx.controls,javafx.fxml,javafx.graphics,javafx.media,javafx.swing,javafx.web"
    echo 
else
    _JAVAFXOPTIONS=""
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant