Changeset 96a30c7 for BLFS


Ignore:
Timestamp:
02/23/2012 05:42:27 PM (13 years ago)
Author:
Pierre Labastie <pierre@…>
Branches:
ablfs
Children:
d7818f5
Parents:
7e51281
Message:

Adds -j1 to "make install", impose a dependency on preceding package in X*
chapter

Location:
BLFS
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • BLFS/gen-special.sh

    r7e51281 r96a30c7  
    7575        </xsl:if>
    7676<!-- Dependencies -->
     77        <xsl:text>
     78            </xsl:text>
     79        <xsl:element name="dependency">
     80          <xsl:attribute name="status">required</xsl:attribute>
     81          <xsl:attribute name="name">
     82            <xsl:value-of
     83              select="preceding-sibling::sect1[1]/@id"/>
     84          </xsl:attribute>
     85          <xsl:attribute name="type">ref</xsl:attribute>
     86        </xsl:element>
    7787        <xsl:apply-templates select=".//para[@role='required' or
    7888                                             @role='recommended' or
  • BLFS/xsl/gen_pkg_list.xsl

    r7e51281 r96a30c7  
    203203          </xsl:if>
    204204<!-- Dependencies -->
     205<!-- If in Xorg chapter, consider that the preceding package is
     206     the first dependency (not always noted in the book) -->
     207          <xsl:if test="ancestor::chapter[@id='x-window-system'] and
     208                        preceding-sibling::sect1[@id != 'xorg7']">
     209            <xsl:text>
     210            </xsl:text>
     211            <xsl:element name="dependency">
     212              <xsl:attribute name="status">required</xsl:attribute>
     213              <xsl:attribute name="name">
     214                <xsl:value-of
     215                  select="preceding-sibling::sect1[1]/@id"/>
     216              </xsl:attribute>
     217              <xsl:attribute name="type">ref</xsl:attribute>
     218            </xsl:element>
     219
     220          </xsl:if>
    205221          <xsl:apply-templates select=".//para[@role='required' or
    206222                                               @role='recommended' or
  • BLFS/xsl/scripts.xsl

    r7e51281 r96a30c7  
    373373  <xsl:template match="screen">
    374374    <xsl:if test="child::* = userinput and not(@role = 'nodump')">
    375       <xsl:if test="@role = 'root' and $sudo = 'y'">
    376         <xsl:text>sudo sh -c '</xsl:text>
    377       </xsl:if>
    378       <xsl:apply-templates select="userinput"/>
    379       <xsl:if test="@role = 'root' and $sudo = 'y'">
    380         <xsl:text>'</xsl:text>
    381       </xsl:if>
     375      <xsl:choose>
     376        <xsl:when test="@role = 'root'">
     377          <xsl:if test="$sudo = 'y'">
     378            <xsl:text>sudo sh -c '</xsl:text>
     379          </xsl:if>
     380          <xsl:apply-templates select="userinput" mode="root"/>
     381          <xsl:if test="$sudo = 'y'">
     382            <xsl:text>'</xsl:text>
     383          </xsl:if>
     384        </xsl:when>
     385        <xsl:otherwise>
     386          <xsl:apply-templates select="userinput"/>
     387        </xsl:otherwise>
     388      </xsl:choose>
    382389      <xsl:text>&#xA;</xsl:text>
    383390    </xsl:if>
     
    437444  </xsl:template>
    438445
     446  <xsl:template match="userinput" mode="root">
     447    <xsl:for-each select="child::node()">
     448      <xsl:choose>
     449        <xsl:when test="self::text() and contains(string(),'make')">
     450          <xsl:value-of select="substring-before(string(),'make')"/>
     451          <xsl:text>make -j1</xsl:text>
     452          <xsl:value-of select="substring-after(string(),'make')"/>
     453        </xsl:when>
     454        <xsl:otherwise>
     455          <xsl:apply-templates select="self::node()"/>
     456        </xsl:otherwise>
     457      </xsl:choose>
     458    </xsl:for-each>
     459  </xsl:template>
     460
    439461  <xsl:template match="replaceable">
    440462<!-- Not needed anymore
Note: See TracChangeset for help on using the changeset viewer.