ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jful...@ruminate.co.uk
Subject Re: ANT Task classpath?
Date Fri, 03 Sep 2004 17:06:31 GMT
Guru Balse <guru.balse@oracle.com> wrote ..
> 
> > u are answering your own question ! your classpath only knows about Test.jar...nothing
> else....I assume Test class is not in
> > your jar...u need to add path ...u could do this by adding class as below
> to your fileset
> 
> I had neglected to mention 2 things:
> 
> 1. Test.jar only has 1 class in it - Test.class, and
> 
> 2. My system claspath has "." in it which is why TestCP.class is picked
> up
> 
> As it turns out, #2 was the key missing point!
> 
> When I did both of the following:
> 
>  * Reorganized Test.jar to contain:
> 
> 	TestCP.class
> 	test/Test.class
> 
>  * Ran the test from a different directory to prevent TestCP.class from
> being loaded from "."
> 
> then everything works fine.
> 
> My guess is that the <classpath> is used ONLY if taskdef is unable to locate
> the class from the system class path.  In other words, since TestCP was
> unresolved from the system class path, Test.jar was loaded.


yes this is correct....u can control this behavior via setting the build.sysclasspath property

http://ant.apache.org/manual/sysclasspath.html

Jim Fuller


Mime
View raw message