ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Price <>
Subject Re: Ant dependencies
Date Mon, 07 Apr 2003 17:12:22 GMT

Dominique Devienne wrote:
> Custom task libraries always need to be explicitly declared in the build
> file using <taskdef> (and possibly <typedef> as well). This element takes
> optional <classpath>, and if not specified, uses the CLASSPATH or whatever's
> in $ANT_HOME\lib (automaticalled added to CLASSPATH by ant.bat/sh). Simply
> specify that nested <classpath> to load the Tomcat Ant library. Ideally,
> you'd avoid absolute paths to find that JAR, and possibly either use an env.
> var. or a Java/Ant property (set ANT_OPTS=-DCATALINA_HOME=... in your env).
> Does that make sense? --DD

Absolutely.  I will have my .antrc set an environment variable (an env 
var set this way should be visible to Ant, right?) and have my build.xml 
check this to build the classpath for the <taskdef>, pointing to the 
catalina-ant.jar file.

If that doesn't work then a properties file will be fine.  I forgot that 
I need to use <taskdef> when using custom tasks, which gives me an 
opportunity to point to the appropriate JAR library.

Thank you Dominique.


View raw message