ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <>
Subject Re: Jikes & <depend> task
Date Thu, 11 Jan 2001 15:32:08 GMT
At 04:31  11/1/01 +0100, Holger Rauch wrote:


>I've been trying to use the <depend> task in my own ant build file and
>have a few questions, since I got an error message telling me that I have 
>to specify the task in a <taskdef> tag (I was looking at the Ant FAQ,
>the documentation and the mailing list archives, but I could not find any
>answers to my questions. Was I overlooking something? If so, I apologize):

<taskdef name="mytask" classname="" />
<mytask file="foo.txt" />

would define a task and use it. Does that help ?

>When using the <depend> task, what do I have to specify for the <taskdef>
>tag? I was looking in optional.jar, 

I don't think you should need to use taskdef tag as ant already defines
these I believe.

>When working with dependencies, I seem to be faced with two alternatives: 
>using the <depend> task or using jikes? Which does a better job?

Depends on a number of things. If you specify
  <property name="build.compiler.depend" value="true"/>
in your build file then I believe they are equivelent. <depend /> is
however better if you need to perform other operations onf the files or if
you want to use the modern/classic javac compilers (or product specific
ones like sjc, msjc etc). <depend /> can also be used to better effect if
you want to check full dependencies and not just for files that changes but
in that case it is slow ;)

If you have small codebases (ie under 100 .java files) it is easier to just
delete all .class and do full recompile with jikes as both <depend /> and
jikes miss a few dependencies. This is usually faster anyways ;)



| "Faced with the choice between changing one's mind, |
| and proving that there is no need to do so - almost |
| everyone gets busy on the proof."                   |
|              - John Kenneth Galbraith               |

View raw message