ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sascha Freitag" <>
Subject RE: Missing & misleading documentation, help needed on advanced Jar functionality
Date Tue, 11 Feb 2003 16:37:06 GMT

What prevent you from adding the activation.jar to the classpath of you own
and distribute both jar's?
I am using a jar that only includes a mainfest file
with a Class-Path and a Main-Class entry to start an amdministration gui.

I build the jar like this:
        <jar destfile="${component.tmp.dir}/${}">
                <attribute name="Class-Path" value="lib/activation.jar
lib/log4j.jar lib/mycomp1.jar lib/mycomp2.jar " />
                <attribute name="Main-Class"
value="org.any.project.admin.GuiMainClass" />

So I have only to make sure that there is a lib folder which contains all
the nessecary jar's.
For that I have a ant deployment target. That could also be a zip file which
could be unpacked
somewhere. After unpacking, the user could double click your jar to start
the app.

Regards Sascha

-----Original Message-----
From: []
Sent: Dienstag, 11. Februar 2003 10:34
Subject: Missing & misleading documentation, help needed on advanced Jar

The problem :
I want to combine all the jars required by my application into a single,
executable jar file. Ant is good for this.
However, the JavaBeans Activation Framework jar needs certain manifest
info, else it generates an error :
Exception in thread "main" java.lang.SecurityException: no manifiest
section for signature file entry

The solution:
Ant docs for jar task indicate it's possible to include manifest
information from a jar file, and combine it with any other info you
include. However, no example is given. It also states falsely, that
"This element is identical to the manifest task".

So I try :
  <manifest file="${activation.jar}">
    <attribute name="Built-By" value="${}"/>
    <attribute name="Main-class" value="mypackage.MyName"/>

Ant complains " doesn't support
the "file" attribute."
So it's not identical.
But I cannot find any other info which allows me to specify how to tell
the jar task where to copy the manifest info from.

It may be more complicated, since look at the contents of activation.jar

Anyone have an idea?


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message