ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 4584] - jlink is broken
Date Fri, 01 Mar 2002 02:22:47 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=4584>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=4584

jlink is broken





------- Additional Comments From bill@jivesoftware.com  2002-03-01 02:22 -------
Here is another possible work around:

Don't use compression="yes". Instead, <jlink> to a temporary jar then use a 
zipfileset in your <jar> task and point to the temp jar. I had to do this and 
it worked fine. (The important part is turning off compression -- that corrupts 
the generated jar file.)

An example:
<target name="jar" depends="compile">
    <mkdir dir="${basedir}/build/lib/temp" />
    <!-- Create a temp jar of all the jars to be included in jive.jar: -->
    <jlink outfile="${basedir}/build/lib/temp/temp.jar">
        <mergefiles>
            <fileset dir="${build.lib.merge.dir}" includes="*.jar" />
        </mergefiles>
    </jlink>
    <jar
        jarfile="${jar.dest.dir}/foo.jar"
        manifest="${resources.dir}/share/manifest.mf"
    >
        <!-- Main .class files: -->
        <fileset dir="${build.dest.dir}" includes="com/foo/**/*.class" />
        <!-- Add in merged jars: -->
        <zipfileset src="${basedir}/build/lib/temp/temp.jar" />
    </jar>
    <delete file="${basedir}/build/lib/temp/temp.jar" />
</target>

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


Mime
View raw message