Change the Java version Eclipse is running under

15,030

Edit the eclipse.ini file to point -vm to JDK 7

Share:
15,030

Related videos on Youtube

Matthias
Author by

Matthias

Digital Illusionist rendering electronic arts while biting frost.

Updated on June 04, 2022

Comments

  • Matthias
    Matthias almost 2 years

    I want to run my Eclipse in a newer Java version (jdk 1.7) because of compatibility problems with the Window Builder Plugin

    "Eclipse is running under 1.6, but this Java project has a 1.7 Java compliance level, so will not be able to load classes from this project. Use a lower level of Java for the project, or run Eclipse using a newer Java version."

    So I suppose, I've to change the vm of Eclipse in the configurations.

    -vm
    C:\Program Files (x86)\Java\jre6\bin\client\jvm.dll
    eclipse.home.location=file:/C:/Program Files (x86)/Eclipse IDE for Java EE Developers/
    eclipse.launcher=C:\Program Files (x86)\Eclipse IDE for Java EE Developers\eclipse.exe
    eclipse.launcher.name=Eclipse
    [email protected]/../p2/
    eclipse.p2.profile=epp.package.jee
    eclipse.product=org.eclipse.epp.package.jee.product
    eclipse.startTime=1351770082498
    eclipse.vm=C:\Program Files (x86)\Java\jre6\bin\client\jvm.dll
    eclipse.vmargs=-Dosgi.requiredJavaVersion=1.5
    

    But I'm not realy familiar with all the statements, and my question is which ones do I've to change in order to run Eclipse with jdk 1.7?

  • Matthias
    Matthias over 11 years
    openFile -vm C:\Program Files\Java\jdk1.7.0_09\jre\bin\server\jvm.dll [guess its this file] -vmargs [already in the file] Result: Eclipse: Failed to load JNI shared library.
  • Matthias
    Matthias over 11 years
    I think it's because of the match 32 bit Eclipse vs 64 bit JDK, although I programmed java projects with a jre 7 64 bit without problems.
  • Ajay George
    Ajay George over 11 years
    you need to be on 64 bit JDK and eclipse to take full advantage of your system. Point the -vm to C:\Program Files\Java\jdk1.7.0_09\bin\javaw.exe
  • Matthias
    Matthias over 11 years
    You mean 64 bit JDK and 64 bit Eclipse? I want to proceed with my 32 bit Eclipse. Result of javaw.exe: Exit code 13. I'm now downloading the 32 bit jdk.