ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Magesh Umasankar" <umag...@apache.org>
Subject Re: jar filesetmanifest=merge is broken?
Date Wed, 08 May 2002 22:30:30 GMT
I have committed a patch to fix this.  It should
work as documented in the next beta release.

Cheers,
Magesh

************************************************
*  Office: A place where you can relax after   *
*  your strenuous home life.                   *
************************************************
----- Original Message -----
From: "klg418" <klg418@bigfoot.com>
To: <ant-user@jakarta.apache.org>
Sent: Saturday, May 04, 2002 3:25 PM
Subject: jar filesetmanifest=merge is broken?


> I am using Ant 1.5-beta1 and Sun JDK 1.4.0 on Windows 2000.
>
> It appears that the "merge" option of the "filesetmanifest" attribute of
the
> "jar" task
> does not work as described. Here are my targets:
>
>     <target name="jar.mk" depends="jar.mklib">
>         <jar jarfile="lib/mk.jar" filesetmanifest="merge" index="true">
>             <zipgroupfileset dir="lib">
>                 <include name="cryptix32.jar"/>
>                 <include name="mklib.jar"/>
>             </zipgroupfileset>
>         </jar>
>     </target>
>
>     <target name="jar.mklib" depends="javac.mk">
>         <manifest file="MicroKernel/manifest.mf">
>             <attribute name="Built-By" value="${user.name}"/>
>             <attribute name="Main-Class"
> value="com.pentasafe.mk.MicroKernel"/>
>         </manifest>
>         <jar jarfile="lib/mklib.jar" manifest="MicroKernel/manifest.mf">
>             <fileset dir="MicroKernel/classes">
>                 <include name="com/pentasafe/**/*.class"/>
>             </fileset>
>         </jar>
>     </target>
>
> There are definitely multiple manifest files in the jars being merged. If
I
> set the
> "filesetmanifest" attribute to "skip", I get warnings as expected. When I
> view the
> "mklib.jar" whose target explicitly specifies a manifest, it does in fact
> contain the
> expected manifest.mf contents. However, the "mk.jar" whose target merges
> several
> jars into one single jar (including "mklib.jar"), the manifest is simply:
>
> Manifest-Version: 1.0
> Created-By: Apache Ant 1.5Beta1
>
> Another thing to consider (this should probably be another post) is
merging
> the
> "index-list" files of multiple jars merged together. The "jar" task just
> adds multiple
> "index-list" entries to the META-INF directory in the jar. Is that
correct?
>
> Other than this, Ant 1.5-beta1 rocks! I really needed the "concat" task. I
> love
> the way the "jar" task can now merge jars instead of using "jlink". The
> "manifest"
> task is also very handy! I can't wait until 1.5 is final -- not to mention
> 2.0!
>
> Kevin Gross
> klg418@bigfoot.com
>
>
> --
> 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