Debian & ubutnu
/Jerry Posted on
Ubuntu7.10 (gutsy) is installed, which causes problems when installing eclipse.
Install eclipse. The source version is 3.2.
- # Sudo apt-Get install eclipse
Install the Java environment
- # Sudo apt-Get install j2sdk1. 4
The following error occurs when you open Eclipse:
JVM terminated. Exit code = 1 (Note: more than 2 GB memory is also prone to this errorCode)
/Usr/lib/j2se/1.4/bin/Java
-Djava. Library. Path =/usr/lib/JNI
-Dgnu. gcj. precompiled. DB. Path =/var/lib/gcj-4.2/classmap. DB
-Dgnu. gcj. runtime. vmclassloader. library_control = never
-Dosgi. Locking = none
-Jar/usr/lib/Eclipse/startup. Jar
-OS Linux
-Ws GTK
-Arch x86
-Launcher/usr/lib/Eclipse/eclipse
-Name eclipse
-Showsplash 600
-Exitdata 178012
-Install/usr/lib/eclipse
-VM/usr/lib/j2se/1.4/bin/Java
-Vmargs
-Djava. Library. Path =/usr/lib/JNI
-Dgnu. gcj. precompiled. DB. Path =/var/lib/gcj-4.2/classmap. DB
-Dgnu. gcj. runtime. vmclassloader. library_control = never
-Dosgi. Locking = none
-Jar/usr/lib/Eclipse/startup. Jar
Search
Let's talk about VM settings on the Internet. Modify eclipse. ini and add-VM.
/Usr/lib/j2se/bin/Java (Java directory). The same error occurs after I modify it. Run eclipse in the command line and you can see that eclipse can
Find the VM. Follow the error message to create a new file.
- # Touch/usr/Local/Lib/Eclipse/. eclipseextension
- # Chmod2775/Usr/Local/Lib/Eclipse/. eclipseextension
- # Chown root: Staff/usr/Local/Lib/Eclipse/. eclipseextension
A new error occurs.
Exception
In thread "Main" Java. Lang. unsupportedclassversionerror:
Org/Eclipse/CORE/launcher/main (unsupportedmajor. Minor version 49.0)
At java. Lang. classloader. defineclass0 (native method)
At java. Lang. classloader. defineclass (classloader. Java: 539)
At java. Security. secureclassloader. defineclass (secureclassloader. Java: 123)
At java.net. urlclassloader. defineclass (urlclassloader. Java: 251)
At java.net. urlclassloader. Access $100 (urlclassloader. Java: 55)
At java.net. urlclassloader $ 1.run( urlclassloader. Java: 194)
At java. Security. accesscontroller. doprivileged (native method)
At java.net. urlclassloader. findclass (urlclassloader. Java: 187)
At java. Lang. classloader. loadclass (classloader. Java: 289)
At sun. Misc. launcher $ appclassloader. loadclass (launcher. Java: 274)
At java. Lang. classloader. loadclass (classloader. Java: 235)
At java. Lang. classloader. loadclassinternal (classloader. Java: 302)
It turns out to be a Java version problem. Unsupported Major. Minor version 49.0 (is the internal version of the Java compiler, 48 indicates that jdk1.4 is used for compiling and running.Program, 49 indicates that the program is compiled and run with jdk1.5 ).
Delete jdk1.4 and install 1.5
- # Sudo apt-Get install sun-java5-jdk
Open eclipse again, no problem