Changeset 6db1464 for LFS


Ignore:
Timestamp:
03/09/2006 10:23:47 PM (18 years ago)
Author:
Manuel Canales Esparcia <manuel@…>
Branches:
experimental
Children:
12a5707
Parents:
1b9148c
Message:

Changed how the testsuites are handled and fixed the missing locales installation for chapter05 testsuites.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • LFS/lfs.xsl

    r1b9148c r6db1464  
    1414<!-- XSLT stylesheet to create shell scripts from LFS books. -->
    1515
    16   <!-- Run optional test suites? -->
    17   <xsl:param name="testsuite" select="0"/>
    18 
    19   <!-- Run toolchain test suites? -->
    20   <xsl:param name="toolchaintest" select="1"/>
     16  <!-- Run test suites?
     17       0 = none
     18       1 = only chapter06 Glibc, GCC and Binutils testsuites
     19       2 = all chapter06 testsuites
     20       3 = all chapter05 and chapter06 testsuites-->
     21  <xsl:param name="testsuite" select="1"/>
    2122
    2223  <!-- Install vim-lang package? -->
     
    7980        </xsl:if>
    8081        <xsl:apply-templates select=".//para/userinput | .//screen"/>
     82        <xsl:if test="$testsuite='3' and @id='ch-tools-glibc'">
     83          <xsl:copy-of select="//sect1[@id='ch-system-glibc']/sect2[2]/screen[@role='nodump']"/>
     84          <xsl:text>&#xA;</xsl:text>
     85        </xsl:if>
    8186        <xsl:text>exit</xsl:text>
    8287      </exsl:document>
     
    8590
    8691  <xsl:template match="screen">
    87     <xsl:if test="child::* = userinput">
    88       <xsl:choose>
    89         <xsl:when test="@role = 'nodump'"/>
    90         <xsl:otherwise>
    91           <xsl:apply-templates select="userinput" mode="screen"/>
    92         </xsl:otherwise>
    93       </xsl:choose>
     92    <xsl:if test="child::* = userinput and not(@role = 'nodump')">
     93      <xsl:apply-templates select="userinput" mode="screen"/>
    9494    </xsl:if>
    9595  </xsl:template>
    9696
    9797  <xsl:template match="para/userinput">
    98     <xsl:if test="$testsuite != '0' and
    99             (contains(string(),'test') or
    100             contains(string(),'check'))">
     98    <xsl:if test="(contains(string(),'test') or
     99            contains(string(),'check')) and
     100            (($testsuite = '2' and
     101            ancestor::chapter[@id='chapter-building-system']) or
     102            $testsuite = '3')">
    101103      <xsl:value-of select="substring-before(string(),'make')"/>
    102104      <xsl:text>make -k</xsl:text>
     
    128130      </xsl:when>
    129131      <!-- The Coreutils and Module-Init-Tools test suites are optional -->
    130       <xsl:when test="$testsuite = '0' and
     132      <xsl:when test="($testsuite = '0' or $testsuite = '1') and
    131133                (ancestor::sect1[@id='ch-system-coreutils'] or
    132134                ancestor::sect1[@id='ch-system-module-init-tools']) and
     
    137139                string() = 'make -k check'">
    138140        <xsl:choose>
    139           <xsl:when test="$toolchaintest = '0'"/>
    140           <xsl:otherwise>
     141          <xsl:when test="(($testsuite = '1' or $testsuite = '2') and
     142                    ancestor::chapter[@id='chapter-building-system']) or
     143                    $testsuite = '3'">
    141144            <xsl:text>make -k check || true</xsl:text>
    142145            <xsl:text>&#xA;</xsl:text>
    143           </xsl:otherwise>
     146          </xsl:when>
    144147        </xsl:choose>
    145148      </xsl:when>
    146149      <xsl:when test="contains(string(),'glibc-check-log')">
    147150        <xsl:choose>
    148           <xsl:when test="$toolchaintest = '0'"/>
    149           <xsl:otherwise>
     151          <xsl:when test="$testsuite != '0'">
    150152            <xsl:value-of select="substring-before(string(),'&#xA;')"/>
    151153            <xsl:text> || true&#xA;</xsl:text>
    152154            <xsl:value-of select="substring-after(string(),'&#xA;')"/>
    153155            <xsl:text>&#xA;</xsl:text>
    154           </xsl:otherwise>
     156          </xsl:when>
    155157        </xsl:choose>
    156158      </xsl:when>
     
    158160                contains(string(),'expect -c')">
    159161        <xsl:choose>
    160           <xsl:when test="$toolchaintest = '0'"/>
    161           <xsl:otherwise>
     162          <xsl:when test="(($testsuite = '1' or $testsuite = '2') and
     163                    ancestor::chapter[@id='chapter-building-system']) or
     164                    $testsuite = '3'">
    162165            <xsl:apply-templates/>
    163166            <xsl:text>&#xA;</xsl:text>
    164           </xsl:otherwise>
     167          </xsl:when>
    165168        </xsl:choose>
    166169      </xsl:when>
Note: See TracChangeset for help on using the changeset viewer.