Return-Path: X-Original-To: apmail-ant-user-archive@www.apache.org Delivered-To: apmail-ant-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 5764417ADE for ; Fri, 20 Mar 2015 07:32:04 +0000 (UTC) Received: (qmail 46996 invoked by uid 500); 20 Mar 2015 07:32:04 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 46946 invoked by uid 500); 20 Mar 2015 07:32:04 -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 46932 invoked by uid 99); 20 Mar 2015 07:32:03 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 20 Mar 2015 07:32:03 +0000 X-ASF-Spam-Status: No, hits=0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE X-Spam-Check-By: apache.org Received-SPF: error (nike.apache.org: local policy) Received: from [212.227.126.187] (HELO mout.kundenserver.de) (212.227.126.187) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 20 Mar 2015 07:31:36 +0000 Received: from JanmySN ([93.130.255.200]) by mrelayeu.kundenserver.de (mreue002) with ESMTPSA (Nemesis) id 0Lwzrl-1ZaDbX2441-016hgD for ; Fri, 20 Mar 2015 08:31:14 +0100 From: =?iso-8859-1?Q?Jan_Mat=E8rne_=28jhm=29?= To: "'Ant Users List'" References: In-Reply-To: Subject: AW: How do I create a customized build? Date: Fri, 20 Mar 2015 08:31:05 +0100 Message-ID: <000e01d062df$d3898ae0$7a9ca0a0$@de> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Office Outlook 12.0 Thread-Index: AdBidL7oXZFm8gCVTi6iNP8kzEhVYwAaalyA Content-Language: de X-Provags-ID: V03:K0:iRdLagp325JYe9ZzaNARwYpUy77Rn5nDJzLH5DNdB/NFav7gsLn JMG6+PUU1+fdT2MmbLc0IG/zanrOfrDjvSjRKrz4tDjTIEaVpemYoKI6075DMT+zGxMLWMj F4/WZ/EkfMJk/D+oI+JorVmWjfA4p/m7WQ1XtXfThXJGZWTX2XNFoZDwAnURvG6zut0Md4P YZpP0jtPOvs9WutKlDpCQ== X-UI-Out-Filterresults: notjunk:1; X-Virus-Checked: Checked by ClamAV on apache.org I would provide several jars: - application-core.jar: contains the application and the interfaces - application-activemq.jar: contains the interface implementations for ActiveMQ - application-hornetq.jar ... The approach you'll try to achieve (as I understand that) is having a = "full jar" for each impl - application-activemq.jar: all for ActiveMQ - application-hornetq.jar: all f=FCr HornetQ... Both strategies would work with pattern. Something like =20 =20 or =20 Some more ideas for improvements: - define a for creating the transport-jars - if you want to build only for the 'current' transport system, use for setting the ${transport-strategy} Jan > -----Urspr=FCngliche Nachricht----- > Von: Gagnon, Joseph - 0558 - MITLL [mailto:Joseph.Gagnon@ll.mit.edu] > Gesendet: Donnerstag, 19. M=E4rz 2015 19:45 > An: user@ant.apache.org > Betreff: How do I create a customized build? >=20 > First let me preface this question by stating that I'm very much an = Ant > newbie. >=20 > I have a Java application that was designed to provide the ability to > "plug > in" a message transport mechanism (e.g. ActiveMQ) for a given client > installation. The code defines interfaces for the transport and then > there > are a number of implementations that conform to the interfaces, > providing > concrete implementations of the transports we support. The idea is > that a > given client will indicate the transport they want/need to use and we > will > provide them with a build that includes only the classes for the = chosen > implementation. No other transport implementations should be included. > The > reasons for this are to keep code size down and for 3rd party = licensing > issues. >=20 > How do you set up an Ant build file to customize the jar file produced > so that > it only includes a subset of the transport implementations? Obviously > I need > to somehow get the transport selection into the build file so that it > has the > info it needs. From what I've read, you have to use properties to get > input > arguments into the script. Beyond that, I am at a loss as to what to > do next. >=20 > I'll provide a brief package hierarchy to illustrate what is located > where. > If it makes sense to restructure this in some way, please let me know. >=20 > .impl > config > TransportConfig.java <- Used to unmarshal a file used to > configure the > transport > transport > impl <- Where the supported transport > implementations live > dds.rti > jms.activemq > udp > > > > .service > TransportFactoryLoader.java <- Uses a ServiceLoader to load a > transport > factory > (currently set up in build file) > .transport <- Contains the interfaces the > transports must > implement > >=20 > So, as an example, client A will be using ActiveMQ. We want to run the > build > so that only the .impl.transport.impl.jms.activemq > classes are > included, but nothing from the rti.dds, udp, etc. packages are > included. I've > tried to find information in this area, but have found nothing helps. >=20 > I am open to any suggestions and ideas about how to go about this. >=20 > Thanks, > Joe Gagnon >=20 > Engineer II > Group 58 - Cyber Systems & Technology > MIT Lincoln Laboratory > Lexington, MA --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org