ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <pe...@apache.org>
Subject Re: article: combining make and ant
Date Thu, 21 Mar 2002 14:02:54 GMT
On Fri, 22 Mar 2002 00:50, stephan beal wrote:
> On Thursday 21 March 2002 14:36 pm, Erik Hatcher wrote:
> > ----- Original Message -----
> > From: "stephan beal" <stephan@einsurance.de>
> >
> > > Make is, let's face it, far better at dependency checking than Ant
> >
> > Care to elaborate on this?  In what way is it better?
>
> oooh, did i open up a can of worms, didn't i?
> It's simpler to use make for dep checking in many cases (examples below).
> In the case of a whole source tree, ant is far easier, at least with source
> files. Setting up deps for non-java files is signficantly more difficult in
> ant.
>
> Make examples:
>
> %.white.png: %.black.png
> 	convert -negate $< $@
>
> %.tab: %.txt
> 	perl myconverter < $< > $@

Yep Make wins n this situation with its ability to do dependency analysis and 
apply ad hoc actions against dependencies. In the future ant should make this 
easier but not quite yet.

> > > take advantage of make's dependency capabilities in allowing it to
> > > build
> >
> > our
> >
> > > custom Ant tasks before it runs the main build.
> >
> > You're saying Ant can't do this?
>
> No, i'm saying it's more work to do in ant. Also, we MUST (in my case) run
> ant multiple times, because of the dependency on not-yet-built custom
> tasks. Ant *cannot* load our build.xml unless these tasks exist and are in
> the classpath before ant starts. Without some sort of front-end (make,
> batch file, whatever), the developer has to run ant twice. Make fills this
> gap for us.

Are you sure ? I have had no probelm of detecting tasks are not built, 
rebuilding them, taskdefing them and then continuing with the build - all 
inside the ant file?

What in particular makes you think you need to restart ant?

> Ant can do most of this stuff, but it cannot do some of the things as
> gracefully as make can. That's not a slight against ant at all - ant can do
> many things that are more difficult in make. For example, climbing down the
> source tree and building the whole thing effectively requires one Makefile
> for each dir, where Ant does it in a few lines of XML.

And theres also bucketloads of things that make does far better than ant -
Ants still relatively young but we are getting there ;)

-- 
Cheers,

Pete

-----------------------------------------------
|  If you turn on the light quickly enough,   |
|    you can see what the dark looks like.    |
-----------------------------------------------

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message