ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marko Srdanovic <Ma...@improv-tech.com>
Subject Can I create a "top level" build file??
Date Mon, 29 Oct 2001 23:24:33 GMT
Hi,

I have a number of projects each in their own directory with their own ant
buildfile (build.xml).  I'd like to create a top level ant project that
simply calls each of the ones in all the directories below it.  I can do
this right now, but I explicitly need to list all the subprojects.  This
gets pretty ugly, as you can imagine.  For example, say my directory
hierarchy is:

  builds/
    build.xml   <===  I want this one to call proj1/build.xml.
proj2/build.xml, and proj3/build.xml with the target (i.e., compile, clean,
etc.)
     proj1/
         build.xml
         src/
     proj2/
         build.xml
         src/
     proj3/
         build.xml
         src/

So my "top level" build.xml looks something like:

<project basedir="." default="all" name="Top level example">
     <target name="all" description="build all the subprojects">
         <ant dir="proj1" target="all"/>
         <ant dir="proj2" target="all"/>
         <ant dir="proj3" target="all"/>
    </target>

     <target name="clean" description="build all the subprojects">
         <ant dir="proj1" target="clean"/>
         <ant dir="proj2" target="clean"/>
         <ant dir="proj3" target="clean"/>
    </target>
</project>

Can I set this up to just build any projects that it "finds".  Something
like <ant dir=-"**">.  Additionally, I'd like to be able to pass different
targets down to the subproject., so that I don't explicitly have list them
all (that may be asking too much though ;-).

Thanks!

Marko Srdanovic
Improv Technologies, Inc.
http://www.improv-tech.com/
535 Eighth Avenue
New York, NY 10018
+1 (917) 438-7121


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


Mime
View raw message