ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ian Duggan <ian.dug...@demandtec.com>
Subject <jar> with multiple <libs> and a <fileset>
Date Wed, 14 Aug 2002 22:05:10 GMT

I'm having trouble getting the <jar> task to do what I want. I am trying to 
use named filesets as the <fileset> and <lib> elements of the <jar> task.

Several things aren't going as expected:

1) The <fileset> excludes aren't picked up. Everything under the <fileset> dir

is being picked up.

2) Only the first <lib> is being honored. The files in the second <lib> 
fileset are not being picked up.

3) The <jar> task complains about the "web.xml" being in the fileset to jar, 
though it is specifically excluded. I think this is a consequence of (1).

Here are the relevant targets and filesets:

        <fileset id="files.war.dtapps"
                 dir="${build.web.dir}/dtapps">
                <exclude name="**/*.java,**/*.class,**/WEB-INF/web.xml"/>
        </fileset>

        <!-- custom jars needed by wars -->
        <fileset id="libfiles.demandtec.war"
                 dir="${build.lib.dir}">
                <include name="${dtweb.jar.file}" />
                <include name="${dtclient.jar.file}" />
        </fileset>

        <!-- standard jars needed by wars -->
        <fileset id="libfiles.standard.war"
                 dir="${build.lib.dir}">
                <include name="struts.jar" />
                <include name="multipart.jar" />
        </fileset>


	<target name="war-dtapps" depends="compile-dtapps">
		<war warfile="${build.archive.dir}/${dtapps.war.file}"
	     		update="true"
	     		manifest="${config.metadata.dir}/dtapps-manifest.mf"
	     		webxml="${build.web.dir}/dtapps/WEB-INF/web.xml">
               		        <fileset refid="files.war.dtapps"/>
                  		<lib refid="libfiles.standard.war"/>
                    		<lib refid="libfiles.demandtec.war"/>
		</war>
	</target>

-- Ian

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Ian Duggan	ian.duggan@demandtec.com	http://www.demandtec.com
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

DemandTec, Inc.
1 Circle Star Way Suite 200 
San Carlos, CA 94070 



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