Search code examples
eclipsehibernatejvmjava-6

Project "MyProject" has higher compiler option than running Eclipse


I am trying to rebuild Hibernate configuration but i got Wrong Compiler Settings error, please find below screenshots of my App configuration and a of the error:

Error Message

Build Path

Java Compiler


Solution

  • The problem was because Eclipse ran on a different JVM than the one specified in my project (I have two installed JDK on my machine), to resolve that i just modified the file eclipse.init in a way to ensure Eclipse will run the appropriate JVM.

    This is what i added to eclipse.init (you need to use your exact path to javaw.exe):

    -vm
    C:\Program Files\Java\jdk1.6.0_45\bin\javaw.exe
    

    Further informations regarding the eclipse.init file, could be found here.