ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <>
Subject AW: Setting Ant classpath
Date Mon, 24 Nov 2008 06:21:55 GMT
>Is it possible to set Ant's classpath from within the build.xml itself?
>Basically, I've got a directory full of libs that contain Ant 
>tasks, and 
>I'd rather not have to specify each one on the command line or in 
><taskdef>s. I'd rather just have a single line in my build.xml 
>that says 
>"put all the jars in this directory on the classpath as if they'd been 
>added on the command line".

<taskdef> supports nested <classpath>.
But some libraries must be added _before_ Ant starts, like bsf,
commons-logging, rhino or xalan.

So another way would be setting the -lib option by
- your own launcher script
- ~/antrc_pre.bat : set variable ANT_ARGS

You could also place your libs in ~/.ant/lib


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message