[ 
https://issues.apache.org/jira/browse/ABDERA-387?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

robert allurent resolved ABDERA-387.
------------------------------------

    Resolution: Not a Problem

Sorry, I have no idea what was going on, but I fixed the issue.

This is the code that helped me:
<?xml version="1.0" encoding="UTF-8"?>
<project default="build" name="jar-bug" basedir="./">
  <target name="build">
    <echo message="testfile" file="build/testfile.txt"/>
    <jar destfile="test.jar" basedir=".">
      <include name="build"/>
      <manifest>
        <!-- If this is an Applet or Web Start application, include
             the proper attributes from 
http://docs.oracle.com/javase/7/docs/technotes/guides/jweb/index.html -->
        <!-- Who is building this jar? -->
        <attribute name="Built-By" value="${user.name}"/>
        <!-- Information about the program itself -->
        <attribute name="Implementation-Vendor" value="ACME inc."/>
        <attribute name="Implementation-Title" value="GreatProduct"/>
        <attribute name="Implementation-Version" value="1.0.0beta2"/>
        <!-- details -->
        <section name="common/MyClass.class">
          <attribute name="Sealed" value="false"/>
        </section>
      </manifest>
    </jar>
    <jar destfile="test.jar" update="true">
      <manifest>
        <attribute name="Application-Name" value="ABCDEF"/>
        <attribute name="Codebase" value="*"/>
        <attribute name="Permissions" value="all-permissions"/>
      </manifest>
    </jar>
  </target>
</project>


> Definitely something wrong with creating manifests.
> ---------------------------------------------------
>
>                 Key: ABDERA-387
>                 URL: https://issues.apache.org/jira/browse/ABDERA-387
>             Project: Abdera
>          Issue Type: Bug
>         Environment: Apache Ant 1.7.0
> Java 1.7.0_51
>            Reporter: robert allurent
>            Priority: Minor
>              Labels: error, manifest
>
> Apache Ant is DEFINITELY generating or reading manifest files incorrectly.
> To prove this, create a jar with a manifest.
> Immediately after creating the jar and manifest, attempt to update the 
> manifest with a permission.
> Simple test case:
>    <jar destfile="${build.lib.dir}/myjar.jar">
>       <fileset dir="${build.bin.dir}/my-code">
>         <include name="**/**" />      
>       </fileset>
>         <fileset dir="${src.dir}" >
>               <include name="net/**/*.gif"/>                    
>               <include name="application/**/*.xml"/>                          
>               <include name="application/**/*.xslt"/>
>               <include name="config/**"/>
>       </fileset>        
>       <manifest>
>     <attribute name="Built-By" value="bodewig"/>
>     <section name="common">
>       <attribute name="Specification-Title" value="Example"/>
>       <attribute name="Specification-Version" value="1.2"/>
>       <attribute name="Specification-Vendor" value="Example Organization"/>
>       <attribute name="Implementation-Title" value="common"/>
>       <attribute name="Implementation-Version" value="1.2 September 10, 
> 2013"/> 
>       <attribute name="Implementation-Vendor" value="Example Corp."/>
>     </section>
>     <section name="common/class1.class">
>       <attribute name="Sealed" value="false"/>
>     </section>
>       </manifest>
>     </jar>
>     <manifest file="${build.lib.dir}/jxntm-admin.jar" mode="update">         
>       <attribute name="Trusted-Only" value="true"/>
>       <attribute name="Permissions" value="all-permissions"/>
>       <attribute name="Codebase" value="*"/>          
>     </manifest>



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to