ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From adammurd...@apache.org
Subject cvs commit: jakarta-ant-myrmidon/tools/xsl build.xsl
Date Wed, 22 May 2002 07:32:10 GMT
adammurdoch    02/05/22 00:32:10

  Modified:    tools/xsl build.xsl
  Log:
  Handle build elements which have no source directories.
  
  Revision  Changes    Path
  1.20      +42 -34    jakarta-ant-myrmidon/tools/xsl/build.xsl
  
  Index: build.xsl
  ===================================================================
  RCS file: /home/cvs/jakarta-ant-myrmidon/tools/xsl/build.xsl,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- build.xsl	19 May 2002 10:48:55 -0000	1.19
  +++ build.xsl	22 May 2002 07:32:10 -0000	1.20
  @@ -405,48 +405,56 @@
           <xsl:param name="build-classes"/>
           <xsl:variable name="patterns" select="patternset"/>
   
  -        <target name="jar-{id}-test-omit" if="xdoclet.omit">
  -            <property name="{id}-xdoclet.omit" value="yep"/>
  -        </target>
  -
  -        <target name="jar-{id}-prepare" depends="jar-{id}-test-omit" unless="{id}-xdoclet.omit">
  -            <uptodate targetfile="${{build.conf}}/{id}/ant-descriptor.xml"
  -                      property="{id}-xdoclet.omit">
  -                <xsl:for-each select="../sourceDirectory">
  -                    <srcfiles dir="{.}">
  -                        <patternset refid="{$build-id}.compile.patternset"/>
  -                        <xsl:copy-of select="$patterns"/>
  -                    </srcfiles>
  -                </xsl:for-each>
  -            </uptodate>
  -        </target>
  -
  -        <target name="jar-{id}-descriptors" depends="jar-{id}-prepare" unless="{id}-xdoclet.omit">
  -            <!-- Generate the descriptors -->
  -            <xsl:if test="not(includeDescriptors = 'false')">
  -                <mkdir dir="${{build.conf}}/{id}"/>
  -                <antlib-descriptor
  -                    destdir="${{build.conf}}/{id}"
  -                    libName="{id}"
  -                    descriptorName="ant-descriptor.xml"
  -                    rolesDescriptorName="ant-roles.xml">
  +        <xsl:if test="../sourceDirectory">
  +
  +            <target name="jar-{id}-test-omit" if="xdoclet.omit">
  +                <property name="{id}-xdoclet.omit" value="yep"/>
  +            </target>
  +
  +            <target name="jar-{id}-prepare" depends="jar-{id}-test-omit" unless="{id}-xdoclet.omit">
  +                <uptodate targetfile="${{build.conf}}/{id}/ant-descriptor.xml"
  +                    property="{id}-xdoclet.omit">
                       <xsl:for-each select="../sourceDirectory">
  -                        <fileset dir="{.}">
  +                        <srcfiles dir="{.}">
                               <patternset refid="{$build-id}.compile.patternset"/>
                               <xsl:copy-of select="$patterns"/>
  -                        </fileset>
  +                        </srcfiles>
                       </xsl:for-each>
  -                    <classpath refid="xdoclet.class.path"/>
  -                    <classpath refid="{$build-id}.class.path"/>
  -                    <classpath path="${{java.class.path}}"/>
  -                </antlib-descriptor>
  -            </xsl:if>
  -        </target>
  +                </uptodate>
  +            </target>
   
  -        <target name="jar-{id}" depends="jar-{id}-descriptors">
  +            <target name="jar-{id}-descriptors" depends="jar-{id}-prepare" unless="{id}-xdoclet.omit">
  +                <!-- Generate the descriptors -->
  +                <xsl:if test="not(includeDescriptors = 'false')">
  +                    <mkdir dir="${{build.conf}}/{id}"/>
  +                    <antlib-descriptor
  +                        destdir="${{build.conf}}/{id}"
  +                        libName="{id}"
  +                        descriptorName="ant-descriptor.xml"
  +                        rolesDescriptorName="ant-roles.xml">
  +                        <xsl:for-each select="../sourceDirectory">
  +                            <fileset dir="{.}">
  +                                <patternset refid="{$build-id}.compile.patternset"/>
  +                                <xsl:copy-of select="$patterns"/>
  +                            </fileset>
  +                        </xsl:for-each>
  +                        <classpath refid="xdoclet.class.path"/>
  +                        <classpath refid="{$build-id}.class.path"/>
  +                        <classpath path="${{java.class.path}}"/>
  +                    </antlib-descriptor>
  +                </xsl:if>
  +            </target>
  +
  +        </xsl:if>
  +
  +        <target name="jar-{id}">
  +            <xsl:if test="../sourceDirectory">
  +                <xsl:attribute name="depends">jar-<xsl:value-of select="id"/>-descriptors</xsl:attribute>
  +            </xsl:if>
   
               <mkdir dir="${{build.conf}}/{id}"/>
               <mkdir dir="{$build-lib}"/>
  +            <mkdir dir="{$build-classes}"/>
   
               <manifest file="${{build.conf}}/{id}/manifest.mf" mode="update">
                   <!-- Add extension info -->
  
  
  

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message