ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dominique Devienne <DDevie...@lgc.com>
Subject RE: copying jars and including them in copy task?
Date Mon, 01 Apr 2002 16:46:55 GMT
This recent thread discussed this. This solution involves using a single
<fileset> refid'd in <path> and used directly in <copy>. Below is just
Diane's solution. Search the archives for the complete thread if this is not
enough. --DD

-----Original Message-----
From: 	Diane Holt [mailto:holtdl@yahoo.com] 
Sent:	Thursday, March 28, 2002 2:57 PM
To:	Ant Users List
Subject:	RE: how to copy a bunch of *unrelated* files ?

As Dominique pointed out, these aren't unrelated files -- they all have a
common root (${user.home}/Developer/Java). I'm not sure why she went with
<patternset>, nor should the common root have been included as part of the
pattern, or where the "ID1" ref came from -- but other than that... :)

Here's the shorter version:
 <fileset id="extlibs.fs" dir="${user.home}/Developer/Java">
   <include name="jaf-1.0.1/lib/activation.jar"/>
   <include name="javamail-1.2/lib/mailapi.jar"/>
   <include name="javamail-1.2/lib/smtp.jar"/>
   <include name="regex4j/regex4j.jar"/>
   <include name="log4j-1.2beta4/dist/lib/log4j-1.2beta4.jar"/>
 </fileset>

 <path id="extlibs.path">
   <fileset refid="extlibs.fs" />
 </path>

Diane


 -----Original Message-----
From: 	Justin Lawler [mailto:justindlawler@eircom.net] 
Sent:	Monday, April 01, 2002 10:39 AM
To:	Ant Users List
Subject:	copying jars and including them in copy task?

I want to have a list of jar files that span multiple directories, eg.

c:/java/program1/program1.jar
c:/java/program2/program2.jar
c:/java/program3/program3.jar

all of which should be included in the classpath for compilation. I also
want them to be copied over to the tomcat ${deploy.home}/WEB-INF/lib
directory when I deploy the application.

How can I define the list of jars only once so that I can include them in
the classpath AND copy them over in a copy command? I'd prefer not to have
two lists of jars to maintain.

as far as I know, the copy task doesn't take in a path.id as an argument?

any help much appreciated,

justin


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

--
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