Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 54690 invoked from network); 25 Apr 2006 17:52:42 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 25 Apr 2006 17:52:42 -0000 Received: (qmail 88797 invoked by uid 500); 25 Apr 2006 17:52:36 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 88754 invoked by uid 500); 25 Apr 2006 17:52:36 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 88743 invoked by uid 99); 25 Apr 2006 17:52:36 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 25 Apr 2006 10:52:36 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of aclose@gmail.com designates 66.249.82.199 as permitted sender) Received: from [66.249.82.199] (HELO xproxy.gmail.com) (66.249.82.199) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 25 Apr 2006 10:52:35 -0700 Received: by xproxy.gmail.com with SMTP id h27so843691wxd for ; Tue, 25 Apr 2006 10:52:14 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=WMgIbHi+CCpzszO1jSCVMuoBqpgmUAUh9PHR/msG36Prp1IpjvQH1tn0Ec6ygtUSLMpiqDEQMxWT6KGlFiuB78lMBQP8sHjeGbHIGaj5Jb6LRTeKYC03DLNF+EIBtN8N20ZTdusu0pW6flk8oHJiiSXbLK61a2YAWh+EqgBNIG4= Received: by 10.70.43.8 with SMTP id q8mr6018425wxq; Tue, 25 Apr 2006 10:52:14 -0700 (PDT) Received: by 10.70.56.6 with HTTP; Tue, 25 Apr 2006 10:52:14 -0700 (PDT) Message-ID: Date: Tue, 25 Apr 2006 12:52:14 -0500 From: "Andrew Close" To: "Ant Users List" Subject: Re: Building from a list... In-Reply-To: <444E0B4A.954F.0081.0@wicourts.gov> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <444E0B4A.954F.0081.0@wicourts.gov> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N On 4/25/06, Andrew Goodnough wrote: > >>> On Tue, Apr 25, 2006 at 11:13 am, in message > , "Andrew > Close" > wrote: > > hello, > > > > i'm having a bit of a brain- fart coming up with a solution to this > > situation. we have about 130 JAR files that we are building for a > > particular project. most of these JARs are dependent on each other > so > > they require a specific build order. i was hoping to create a list > of > > the projects that compose each JAR and feed this list to ANT to > build > > one at a time. i know the Ant- Contrib project has a tag > > that allows for iteration, but i'm a bit stumped on how to build > > everything from a properties file. is this possible? or is there a > > better way to approach this? > > > > we're using VSS as source control and have several projects that are > > composed of several (130+) products/JARs in VSS. so i'd like to > make > > a list of Project.Product that i can iterate through and > > build/JAR/deploy in order. > > so in VSS we may have Project1 that contains ProductA, ProductB & > > ProductC and Project2 that contains ProductD & ProductE and Project3 > > that contains ProductF, ProductG & ProductH. the build order may > end > > up being: > > ProductB, ProductG, ProductA, ProductC, ProductD, ProductF, > ProductE... > > so my initial idea was to create a master list that contains these > > products in their proper build order: > > Project1.ProductB > > Project3.ProductG > > Project1.ProductA > > Project1.ProductC > > Project2.ProductD > > Project3.ProductF > > Project2.ProductE > > > > our ANT build file is currently set up to build products > individually. > > so typically we'd pass in the ProjectName, ProductName, Branch, > > DeliverableType and DeploymentDest to build one product/JAR/etc. to > > build all applications (build world) we have to either type this in > > manually 130+ times or we use a .bat file that makes 130+ calls. > the > > problem with the .bat file is that if product 15 fails a bunch of > > builds that follow will fail due to dependency. there is no good > way > > to stop the build process on error. so i was hoping ANT would be > able > > to come to the rescue. :) > > hopefully this is enough background to either come up with a > solution > > or generate some discussion that will lead to a solution. > > thanks for any help you can offer. > > > > > --------------------------------------------------------------------- > > To unsubscribe, e- mail: user- unsubscribe@ant.apache.org > > For additional commands, e- mail: user- help@ant.apache.org > > We have a large amount of projects with interdependencies, too. Our > process sets up a set of files (with pre-defined names) which allow the > project owner to configure dependencies, including triggering > sub-builds, in any. First, here's how the classpath is setup for the > compile. The "includesfile" property includes from the files. > > > > > includesfile=3D"${sharedjars.depend.file}"/> > > > A typical jars.depend file looks like this: > > =3D=3D=3Djars.depend=3D=3D=3D > xml-apis.jar > xerces-2_0_1.jar > xalan-j_2_3_1.jar > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > and > > =3D=3D=3Dclasses.depend=3D=3D=3D > Global-Utils/build/classes > Parent-Proj/build/classes > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > > Second, if in addition to including the classes from Global-Utils and > Parent-Proj, you want this project to build both projects before > building itself, then have your compile target depend on sub-compile > target like: > > > > > > > > description=3D"Compiles the source files"> > destdir=3D"${build.classes}"> > > > > > > where you put the 2 projects in the projects.depend: > > =3D=3D=3Dprojects.depend=3D=3D=3D > Global-Utils > Parent-Proj > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > > Each project must have standard target names to use this scheme, but it > scales well. We use Entity references to gain a type of inheritance in > Ant to reuse common targets but that's another topic. Good luck! Andy, thanks for your reply. so do you have a single task/target that you kick off that builds everything for you? would i end up with 130+ individual targets that depend on each other in your scenario? i.e: this scenario is what i was hoping to avoid by building a list of projects to be build in the correct order. maybe i'm missing something though... --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org