ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gunnar Sigurdsson <gun...@comnipoint.com>
Subject taskdef classpath problem
Date Thu, 29 Dec 2005 05:14:52 GMT
I am using ant version 1.6.2. 

I have a custom task, com.xxx.ant.abc.GenDDL, which is stored 
in a jar file which is in the "lib" directory indicated in the 
"fileset" below.

<target name="ddl">
    <taskdef name="genddl"
             classname="com.xxx.ant.abc.GenDDL">
        <classpath>
            <fileset dir="lib">
                <include name="*.jar"/>
            </fileset>
        </classpath>
    </taskdef>
    <genddl/>
</target>

The GenDDL class depends on other jar files that are in the same 
"lib" directory. When the "ddl" target is executed, ant finds the 
GenDDL class and executes it, but it does not find resources in the 
other jar files. 

When I execute this command:

  $ ant -lib lib ddl

things work fine.

Because of our environment, I cannot require the use of the -lib option, 
or require copying of jars into $ANT_HOME, or $HOME/.ant/lib.

Is there any way for me to specify all the resources needed by the task 
within the taskdef itself?

Help will be much appreciated.

Gunnar


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


Mime
View raw message