Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Perhaps JAVA_HOME does not point to the JDK..error?

 
Vinod Vinu
Ranch Hand
Posts: 217
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Im getting the following error while running the hbm2pojo.xml file on eclipse:-

BUILD FAILED
C:\Projects\scc\capability\build\hbm2pojo.xml:56: Unable to find a javac compiler;
com.sun.tools.javac.Main is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK
 
Jesper de Jong
Java Cowboy
Saloon Keeper
Posts: 15214
36
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JAVA_HOME is an environment variable. It's not required to set this for Java itself, but some tools use this to find the JDK. You're probably running some tool which expects this environment variable to be set.

Set the environment variable and restart Eclipse, and try to do it again. How you set the environment variable depends on which version of Windows you are using exactly. On Windows Vista, it is: right-click on My Computer, select Properties, Advanced System Settings, Advanced, button Environment Variables. Add it to the System variables (lower half of the window).
 
Rob Spoor
Sheriff
Pie
Posts: 20511
54
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What do you get when you open a command prompt and execute "echo %JAVA_HOME%" (without the quotes)?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic