You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4cxx-user@logging.apache.org by Andreas Grob <an...@bergauer.ch> on 2008/01/15 09:57:59 UTC

Unable to locate tools.jar

Hi,

After installing a new java version I got following error:

Unable to locate tools.jar. Expected to find it in 
C:\Programme\Java\jre1.6.0_04\lib\tools.jar
Buildfile: build.xml

Well, my workaround is to copy tools.jar from the path 
...\jdk1.6.0_04\lib to the expected place. Is there a better way?

Cheers
~ Andreas



Re: Unable to locate tools.jar

Posted by Curt Arnold <ca...@apache.org>.
On Jan 15, 2008, at 2:57 AM, Andreas Grob wrote:

> Hi,
>
> After installing a new java version I got following error:
>
> Unable to locate tools.jar. Expected to find it in
> C:\Programme\Java\jre1.6.0_04\lib\tools.jar
> Buildfile: build.xml
>
> Well, my workaround is to copy tools.jar from the path
> ...\jdk1.6.0_04\lib to the expected place. Is there a better way?
>
> Cheers
> ~ Andreas
>
>

tools.jar is included with a JDK, but not with a JRE.  Ant emits a  
warning if it can't find tools.jar, since it assumes that it  
eventually be asked to do java compilation which is performed using  
tools.jar.  In our case, we don't ask Ant to do java compilation so  
the warning is innocuous.  The warning could be avoided by either  
having a JDK first in the path, or by setting the environment variable  
JAVA_HOME to the JDK's root directory (likely C:\Programme\Java 
\jdk1.6.0_04).