Linux, com/apple/mrj/MRJQuitHandler

Subscribe to Linux, com/apple/mrj/MRJQuitHandler 2 post(s), 1 voice

 
Avatar Hartmut 3 post(s)

Hi,
I’ve taken the current source codes with “git clone https://github.com/cyberfox/jbidwatcher.git”
Under Debian and Java 8 I made “ant clean” and then “and linux”
Everything compiled fine, but when I run the program with “java -jar JBidwatcher.jar”, I receive the error below as result. I think I am totally wrong at some point, but cannot explain these apple dependencies which are not exist on Debian?.
Is possible to compile under linux?
I appreciate Your help :)
Greetings!
Hartmut


Error: A JNI error has occurred, please check your installation and try again
Exception in thread “main” java.lang.NoClassDefFoundError: com/apple/mrj/MRJQuitHandler
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:760)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:467)
at java.net.URLClassLoader.access$100(URLClassLoader.java:73)
at java.net.URLClassLoader$1.run(URLClassLoader.java:368)
at java.net.URLClassLoader$1.run(URLClassLoader.java:362)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:361)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
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:544)
at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:526)
Caused by: java.lang.ClassNotFoundException: com.apple.mrj.MRJQuitHandler
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
… 19 more

 
Avatar Hartmut 3 post(s)

I added the library mrjtoolkitstubs-1.0.jar to the lib directory, adapted the build.xml file, and the main difference,

i called

java -jar JBidwatcher-2.99pre5.jar

instead of

java -jar JBidwatcher.jar

Then this issue was solved ! :-)