ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Antoine Lévy-Lambert <anto...@antbuild.com>
Subject Re: Ant 1.6.0 Long Filename support
Date Sun, 11 Jan 2004 16:17:42 GMT
Graham Reeds wrote:

>
>>- what is the value of ANT_HOME in your system,
>>    
>>
>
>ANT_HOME = C:\Program Files\Apache Group\apache-ant-1.6.0
>
>  
>
>>- what is the value of JAVA_HOME
>>    
>>
>
>JAVA_HOME = C:\Program Files\Java\jdk1.3.1_09
>
>  
>
>>- is CLASSPATH set as an environment variable before you start ant; if
>>it is set, can you try running ant without CLASSPATH,
>>    
>>
>
>When I run without the CLASSPATH it complains that build.xml wasn't found
>(my working directory had defaulted to desktop due to the text file that
>held my CLASSPATH settings). Change to my working directory and - hey
>presto - it worked (sort of).
>
>  
>
>>- can you start ant from the command prompt (directly without TextPad
>>and your "tool"),
>>    
>>
>
>When I run it with CLASSPATH set it gives 'Files\Apache was unexpected at
>this time.'  Works without.
>
>  
>

1) it sounds like there is a bug in ant.bat which is showing up when 
CLASSPATH contains embedded spaces. I need to check this.

>However I now get compile errors with

>    [javac] Compiling 1 source file to
>C:\java\jakarta-tomcat-3.2.3\webapps\utopia\WEB-INF\classes
    [javac] D:\develop\www.digital-utopia.co.uk\src\UtopiaServlet.java:8:
>package javax.servlet does not exist
    [javac] import javax.servlet.*;

>Which means it can't import the packages - CLASSPATH is still needed.  I
>tried setting the CLASSPATH in the ant.bat but that brings back the earlier
>error.

2) to run ant without CLASSPATH set, change your build files to include explicitly servlet.jar
or j2ee.jar in the classpath when compiling your servlets,

using the classpath nested element of javac.

something like this
<property environment="env"/>
<javac ....>
    <classpath>
           <pathelement 
location="${env.CATALINA_HOME}/common/lib/servlet.jar"/>
          ... other path elements needed to compile your servlets
     </classpath>
</javac>

> I thought CLASSPATH was an integral part of Tomcat and ergo reluctant to
> remove it.  I am suprised that when I had tomcat and apache installed in
> directories without spaces I never encountered this error or is this a new
> feature with 1.6?

I would be surprised to hear that there is a requirement to have the 
CLASSPATH environment variable set at system level to be able to run tomcat.
I had installed a 4.x tomcat on my PC and there was no such requirement.


Cheers,

Antoine


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message