Skip to main content



      Home
Home » Language IDEs » Java Development Tools (JDT) » How do I configure ant for the sources of Thinking in Java's book?
How do I configure ant for the sources of Thinking in Java's book? [message #156896] Sat, 01 May 2004 05:27 Go to next message
Eclipse UserFriend
Originally posted by: gabalin.yahoo.com

I have downloaded the sources from Thinking in Java's book written by
Bruce Eckels and I've used the Eclipse editor to run some classes. My
question is
how to include and build the classes that come with these sources inside
Eclipse?. I've tried to used the External tool from Eclipse but it
didn't work. The error that I have is

JDK.version.check:
[javac] Compiling 1 source file
[javac] BUILD FAILED: file:C:/Program
Files/eclipse/plugins/Code/c02/build.xml:31: 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

I know that I have to set the CLASSPATH but I don't know how. It is
clear that Java doesn't recognize the path indicated by the .xml file.
So, could you explain me which CLASSPATH file update and how must I
accomplish the task.
However the rest of the classes that come with Eclipse are well pointed
out by the external tool.
Regards,

Pepe
Re: How do I configure ant for the sources of Thinking in Java's book? [message #156920 is a reply to message #156896] Sat, 01 May 2004 11:51 Go to previous message
Eclipse UserFriend
Window>Preferences>Ant>Runtime>Classpath
Add the appropriate tools.jar from your JDK install
http://www.eclipse.org/eclipse/faq/eclipse-faq.html#users_16

Or simple start Eclipse using the -vm option to point to your JDK install
http://help.eclipse.org/help21/index.jsp?topic=/org.eclipse. platform.doc.user/tasks/running_eclipse.htm

Or (in 3.0 later builds) set your JAVA_HOME environment variable to point to
your JDK install

HTH
Darins

"Pepe Sanchez" <gabalin@yahoo.com> wrote in message
news:c6vqhs$vgh$1@eclipse.org...
> I have downloaded the sources from Thinking in Java's book written by
> Bruce Eckels and I've used the Eclipse editor to run some classes. My
> question is
> how to include and build the classes that come with these sources inside
> Eclipse?. I've tried to used the External tool from Eclipse but it
> didn't work. The error that I have is
>
> JDK.version.check:
> [javac] Compiling 1 source file
> [javac] BUILD FAILED: file:C:/Program
> Files/eclipse/plugins/Code/c02/build.xml:31: 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
>
> I know that I have to set the CLASSPATH but I don't know how. It is
> clear that Java doesn't recognize the path indicated by the .xml file.
> So, could you explain me which CLASSPATH file update and how must I
> accomplish the task.
> However the rest of the classes that come with Eclipse are well pointed
> out by the external tool.
> Regards,
>
> Pepe
>
Previous Topic:add my own content assist to java editor?
Next Topic:default editor not found
Goto Forum:
  


Current Time: Tue May 06 15:13:47 EDT 2025

Powered by FUDForum. Page generated in 0.13377 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top