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

Pre-compiled binaries throw version error #3

Open
ELLIOTTCABLE opened this issue Aug 4, 2013 · 3 comments
Open

Pre-compiled binaries throw version error #3

ELLIOTTCABLE opened this issue Aug 4, 2013 · 3 comments

Comments

@ELLIOTTCABLE
Copy link

Getting the following from the bit.ly-download-able binary, v1.1:

> java -jar ~/Downloads/cli-nbt-v1.1.jar 
Exception in thread "main" java.lang.UnsupportedClassVersionError: com/gn32/apps/clinbt/Main : Unsupported major.minor version 51.0
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
    at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
    at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
@DarkStorm652
Copy link
Contributor

It was compiled under Java 7 (51.0), so you need JRE/JDK 7 to run it.

@ELLIOTTCABLE
Copy link
Author

I'm running the latest JRE:

screenshot on 2013-08-05 at 15 58 07

Is there something else I should be doing? :x

@DarkStorm652
Copy link
Contributor

"Unsupported major.minor version 51.0" indicates that the JVM doesn't support class version 51.0 (which is Java 7). Make sure that the Java you're using from terminal is the same one you see in the GUI. Do java -version to verify, and if in fact it isn't the same one, you have to specify the exact path to the java binary (somewhere likely in /Library/Java/Home, but make sure it's the Java 7 one).

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

2 participants