ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Smiley <>
Subject Re: "available" shouldn't actually load the class; just see if it's resolvable
Date Tue, 09 Nov 2004 19:27:45 GMT
Does anyone want to offer their opinion?  It should be an easy change 
and I think it would be very unlikely if this broke any existing builds.

~ Dave

David Smiley wrote:
> Hello.  Recently I got the uddi4j source and I rant it's ant build 
> script.  It turns out that it would conditionally compile some extras if 
> I have Apache's soap & axis projects on the classpath.  I checked this via:
>     <available classname="org.apache.soap.messaging.Message"
>                property="apache-soap.available" />
>     <available classname="org.apache.axis.Constants"
>                property="apache-axis.available" />
> Okay, so I rant ant again but I used the -lib option to specify those 
> two jars.  However, ant failed to set those two properties!  I did a lot 
> of troubleshooting, trying everything, and then I tried the ant -debug 
> option which revealed the problem.  Ant was trying to actually load the 
> classes in question (instead of just seeing if they are available) which 
> in turn caused it to load dependent classes --some of which were not on 
> the classpath.
> I don't think ant's "available" task should actually load the class. 
> Just see if the class is available by doing a getResource or something 
> like that.
> ~ David Smiley

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

View raw message