File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes Perhaps JAVA_HOME does not point to the JDK..error? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Perhaps JAVA_HOME does not point to the JDK..error?" Watch "Perhaps JAVA_HOME does not point to the JDK..error?" New topic
Author

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

Vinod Vinu
Ranch Hand

Joined: Aug 30, 2009
Posts: 217
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


Vinod Kumar Nair
"Any fool can write code that a computer can understan. Good programmers write code that humans can understand."
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 13884
    
  10

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).

Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19556
    
  16

What do you get when you open a command prompt and execute "echo %JAVA_HOME%" (without the quotes)?


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Perhaps JAVA_HOME does not point to the JDK..error?
 
Similar Threads
error while invoking jndi list in jmx - console
Ant script execution fails
JasperException Error
Help with Ant build
new to jsp----a small problem about jsp compile