ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "SAINI,DEEPA (Non-A-PaloAlto,ex2)" <deepa_sa...@non.agilent.com>
Subject RE: Manifest file validation in Jar
Date Thu, 06 Sep 2001 01:02:29 GMT
Got it. Since there was an empty line before the Main-Class line, it was
taking it to be part of the other section and not the main section.

Thanks,
Deepa.

-----Original Message-----
From: Conor MacNeill [mailto:conor@cortexebusiness.com.au]
Sent: Wednesday, September 05, 2001 4:29 PM
To: ant-user@jakarta.apache.org
Subject: RE: Manifest file validation in Jar


Please read
http://java.sun.com/j2se/1.3/docs/guide/jar/jar.html#JAR%20Manifest

and create a valid manifest file.

> -----Original Message-----
> From: SAINI,DEEPA (Non-A-PaloAlto,ex2)
> [mailto:deepa_saini@non.agilent.com]
> Sent: Thursday, 6 September 2001 8:42 AM
> To: 'ant-user@jakarta.apache.org'
> Subject: Manifest file validation in Jar
> 
> 
> Hello,
> 
> I am creating a jar file including the manifest file in it. The manifest
> file stores the version information and Main-Class, Class-Path, etc. With
> Ant 1.3 it used to work fine. But Ant 1.4 gives me the following error:
> 
>  [jar] Manifest is invalid: Manifest sections should start with a "Name"
> attribute and not "Main-Class"
> 
> BUILD FAILED
> 
> D:\views\LATEST_view\BioInformatics\applications\mondavi\src\biogr
> apher\biog
> rapher.xml:58: Invalid Manifest:
> D:\views\LATEST_view\BioInformatics\applications\mondavi\META-INF\
> biographer
> \MANIFEST.MF
> 	at org.apache.tools.ant.taskdefs.Jar.setManifest(Jar.java:116)
> 	at java.lang.reflect.Method.invoke(Native Method)
> 	at
> org.apache.tools.ant.IntrospectionHelper$15.set(IntrospectionHelpe
> r.java:530
> )
> 	at
> org.apache.tools.ant.IntrospectionHelper.setAttribute(Introspectio
> nHelper.ja
> va:276)
> 	at
> org.apache.tools.ant.ProjectHelper.configure(ProjectHelper.java:658)
> 	at
> org.apache.tools.ant.RuntimeConfigurable.maybeConfigure(RuntimeCon
> figurable.
> java:143)
> 	at org.apache.tools.ant.Task.maybeConfigure(Task.java:178)
> 	at org.apache.tools.ant.Task.perform(Task.java:216)
> 	at org.apache.tools.ant.Target.execute(Target.java:164)
> 	at org.apache.tools.ant.Target.performTasks(Target.java:182)
> 	at org.apache.tools.ant.Project.executeTarget(Project.java:601)
> 	at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:256)
> 	at org.apache.tools.ant.Task.perform(Task.java:217)
> 	at org.apache.tools.ant.Target.execute(Target.java:164)
> 	at org.apache.tools.ant.Target.performTasks(Target.java:182)
> 	at org.apache.tools.ant.Project.executeTarget(Project.java:601)
> 	at org.apache.tools.ant.Project.executeTargets(Project.java:560)
> 	at org.apache.tools.ant.Main.runBuild(Main.java:454)
> 	at org.apache.tools.ant.Main.start(Main.java:153)
> 	at org.apache.tools.ant.Main.main(Main.java:176)
> --- Nested Exception ---
> org.apache.tools.ant.taskdefs.ManifestException: Manifest sections should
> start with a "Name" attribute and not "Main-Class"
> 	at org.apache.tools.ant.taskdefs.Manifest.<init>(Manifest.java:471)
> 	at org.apache.tools.ant.taskdefs.Jar.setManifest(Jar.java:108)
> 	at java.lang.reflect.Method.invoke(Native Method)
> 	at
> org.apache.tools.ant.IntrospectionHelper$15.set(IntrospectionHelpe
> r.java:530
> )
> 	at
> org.apache.tools.ant.IntrospectionHelper.setAttribute(Introspectio
> nHelper.ja
> va:276)
> 	at
> org.apache.tools.ant.ProjectHelper.configure(ProjectHelper.java:658)
> 	at
> org.apache.tools.ant.RuntimeConfigurable.maybeConfigure(RuntimeCon
> figurable.
> java:143)
> 	at org.apache.tools.ant.Task.maybeConfigure(Task.java:178)
> 	at org.apache.tools.ant.Task.perform(Task.java:216)
> 	at org.apache.tools.ant.Target.execute(Target.java:164)
> 	at org.apache.tools.ant.Target.performTasks(Target.java:182)
> 	at org.apache.tools.ant.Project.executeTarget(Project.java:601)
> 	at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:256)
> 	at org.apache.tools.ant.Task.perform(Task.java:217)
> 	at org.apache.tools.ant.Target.execute(Target.java:164)
> 	at org.apache.tools.ant.Target.performTasks(Target.java:182)
> 	at org.apache.tools.ant.Project.executeTarget(Project.java:601)
> 	at org.apache.tools.ant.Project.executeTargets(Project.java:560)
> 	at org.apache.tools.ant.Main.runBuild(Main.java:454)
> 	at org.apache.tools.ant.Main.start(Main.java:153)
> 	at org.apache.tools.ant.Main.main(Main.java:176)
> 
> 
> My manifest file looks like :
> 
> Manifest-Version: 1.0
> Name: Mondavi
> Specification-Version: 1.2
> Implementation-Version: 14
> 
> Main-Class: BioGrapher
> 
> Any solution?
> 
> Thanks,
> Deepa.
> 

Mime
View raw message