ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Conor MacNeill <>
Subject Re: Depend Task..
Date Wed, 11 Dec 2002 05:25:56 GMT
Ram Krish wrote:
> Hi,
>    I have very liitle knowledge in Ant.Whats the
> advantage of Depend task over javac 

If class A depends on class B and is changed, the <javac> task 
will not recompile even though class B may have changed its 
interface. If it hasB has changes, the result may be a runtime error 
(IncompatibleClassChangeError). The depend task analyses class 
dependencies and if A depends on B and has changed, it will 
delete A.class, forcing to be recompiled. The interface change 
would then cause some sort of compilation error.

<depend> is not perfect as it relies on class file dependencies. Most, 
but not all, source level dependencies result in class filedependencies. 
In particular, static final constants do not.

and how to combine
> them effectivwly for building projects?..(i am using
> JDK1.3.1)

Just put a <depend> task before <javac> in your build target and use the 
same parameters.


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

View raw message