ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Esterkin <dester...@chariotsolutions.com>
Subject Problem nesting presetdef in another task
Date Thu, 29 Jul 2004 19:12:12 GMT
Hello,

I created a presetdef of a <manifest> element, and then tried to use it as a sub-element
of <jar>.

When I execute the script, the build fails with a message stating this is an unsupported nested
element.


Here is a sample build script.  In addition, to the form shown below, I have tried defining
the 
presetdef outside of any targets (as a direct sub-element of project),
------------------------------
<?xml version="1.0"?>
<project name="anttest" default="jar" basedir=".">

     <target name="jar">
         <presetdef name="my.manifest">
             <manifest>
                 <attribute name="Built-By" value="${user.name}"/>
             </manifest>
         </presetdef>

         <jar jarfile="anttest.jar" basedir="." includes="build.xml">
              <my.manifest/>
         </jar>
     </target>
</project>
------------------------------

Here is the output from executing the script above:
BUILD FAILED
/java/projects/anttest/build.xml:11: The <jar> type doesn't support the nested "my.manifest"
element.


Thanks for any help with this.

David


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message