Java Mailing List Archive

http://www.ant-tasks.com/

Apache Ant Archive

» Ant Users List
» Ant Developers List
Zipfileset in <path >

Zipfileset in <path >

2003-02-11       - By Casey Daniell
Reply:     1     2     3  

I have several jar files, realmutils.jar, arch.jar. base.jar which contain
classes that I need in various other jar files,  rbac.jar and  client.jar.

Is there anyway that I can use the zipfileset task within a <path> type tag?
What I am trying to do is similar to the below:

Create a path id to reference later in the build process, not all files in
any jar file is included this is selecting a subset of classes in each jar:

<path id="bac-client-files">
  <fileset dir="com/realm/portal/data/security/rbac/ejb">
     <exclude name="**/jboss.xml"/>
     <include name="META-INF/*.xml"/>
  </fileset>
  <zipfileset src="${parentdir}/lib/realmutils.jar"
                  includes="com/realm/utils/string/StringCipher.class"/>
  <zipfileset src="${parentdir}/lib/arch.jar"
                  includes="com/realm/utils/log/ILogger.class"/>
  <zipfileset src="${parentdir}/lib/arch.jar"
                  includes="com/realm/utils/log/RealmLogger.class"/>
  <zipfileset src="${parentdir}/lib/base.jar"  
</path>

With the path id created I would then like to build my multiple jar files
referencing the id "bac-client-files", and adding in some other files
specific to each jar:

<jar destfile="${rbac.jar}">
    <fileset refid="bac-client-files"/>
    <....other files added here.....>
</jar>

The above code needs to be run for a couple of different jar files that all
contain the "bac-client-files".

Is there a way to accomplish this? I am getting, "The <path> data type
doesn't support the the nested "zipfile" element" error message when I try
to create the <path> above.

Thanks,
Casey B. Daniell
Realm Business Solutions, Inc.
13727 Noel Rd. Suite 800
Dallas, TX 75240
cdaniell@(protected) <mailto:cdaniell@(protected)>
O:(469) 791-1065
C:(512) 589-3667


©2008 ant-tasks.com - Jax Systems, LLC, U.S.A.