aspose file tools*
The moose likes Struts and the fly likes Manifest file problem. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Manifest file problem." Watch "Manifest file problem." New topic
Author

Manifest file problem.

sri valli
Greenhorn

Joined: Oct 20, 2008
Posts: 20
Hi,
we are using an application for which we are not able to create .ear file.
we investigated that the problem is with the manifest file.
the manifest file is not created.
please some body can give any pointers like under what conditions we face this scenario?
Any help would be appreciated
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8705
    
    6

You need to Tell The Details.
How are you trying to create an EAR?
What led you to believe the manifest file is the problem?
Exactly what errors are you seeing?
[ November 10, 2008: Message edited by: Joe Ess ]

"blabbing like a narcissistic fool with a superiority complex" ~ N.A.
[How To Ask Questions On JavaRanch]
sri valli
Greenhorn

Joined: Oct 20, 2008
Posts: 20
Hi,
the problem is we are trying to build .ear file using ant commands which are defined in build.xml file.
in the build.xml there is a command to create manifest file.
but we found out that the manifest file is not creating under /meta-inf diractory.
we assume that this could be the problem forthe creation of .ear file.
and i don't have much knoledge on build.xml file.so
i am giving all the commands which are existing in my build.xml file related to manifest file.


INITIALIZATION SECTION
=========================


<available file="${conf.dir}/MANIFEST.MF" property="has.custom.manifest" />
- <condition property="do.war.package.with.custom.manifest">
- <and>
<istrue value="${war.package}" />
<isset property="has.custom.manifest" />
</and>
</condition>
- <condition property="do.war.package.without.custom.manifest">
- <and>
<istrue value="${war.package}" />
- <not>
<isset property="has.custom.manifest" />
</not>
</and>
</condition>

COMPILATION SECTION
===================

- <target name="-do-compile" depends="init, deps-jar, -pre-pre-compile, -pre-compile, -copy-manifest, -copy-webdir, library-inclusion-in-archive,library-inclusion-in-manifest" if="have.sources">
<webproject2:javac destdir="${build.classes.dir.real}" />
- <copy todir="${build.classes.dir.real}">
<fileset dir="${src.dir}" excludes="${build.classes.excludes}" />
</copy>
</target>
- <target name="-copy-manifest" if="has.custom.manifest">
<mkdir dir="${build.meta.inf.dir}" />
- <copy todir="${build.meta.inf.dir}">
<fileset dir="${conf.dir}" includes="MANIFEST.MF" />
</copy>
</target>

DIST BUILDING SECTION
======================

- <target name="-do-dist-with-manifest" if="do.war.package.with.custom.manifest" depends="init,compile,compile-jsps,-pre-dist">
<dirname property="dist.jar.dir" file="${dist.war}" />
<mkdir dir="${dist.jar.dir}" />
- <jar manifest="${build.meta.inf.dir}/MANIFEST.MF" jarfile="${dist.war}" compress="${jar.compress}">
<fileset dir="${build.web.dir.real}" />
</jar>
</target>
<target name="do-dist" depends="init,compile,compile-jsps,-pre-dist,-do-dist-with-manifest,-do-dist-without-manifest" />
- <target name="library-inclusion-in-manifest" depends="init" if="dist.ear.dir">
<basename property="included.lib.file.reference.jato-1_2_2-dev4.jar" file="${file.reference.jato-1_2_2-dev4.jar}" />
<copy-ear-war file="${file.reference.jato-1_2_2-dev4.jar}" propname="included.lib.file.reference.jato-1_2_2-dev4.jar.X" />
<mkdir dir="${build.web.dir.real}/META-INF" />
- <manifest file="${build.web.dir.real}/META-INF/MANIFEST.MF" mode="update">
<attribute name="Class-Path" value="${included.lib.file.reference.jato-1_2_2-dev4.jar}" />
</manifest>

Thanks in advance
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8705
    
    6

What is the output of the ant command?
The code you posted does not have a close tag for the name="do-dist" target. Is this an oversight?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Manifest file problem.
 
Similar Threads
How to Creat Executable Jar File ??
Mig Layout
manifest file
Beans
select another dropdown based on a selection from first dropdown using <html:select> struts tag