Changed the pkgmngt part of lfs.xsl so that no script is created if

packageManager.xml has not <screen><userinput> nodes for that
This commit is contained in:
Pierre Labastie 2012-02-23 14:12:55 +00:00
parent 59364d06eb
commit 7e51281ea6

View file

@ -244,7 +244,11 @@ fi
<xsl:variable name="pi-file-value" select="substring-after($pi-file,'filename=')"/>
<xsl:variable name="filename" select="substring-before(substring($pi-file-value,2),'.html')"/>
<!-- Creating dirs and files -->
<exsl:document href="{$dirname}/{$order}-{position()}-{$filename}" method="text">
<xsl:if test="count(descendant::screen/userinput) &gt; 0 and
count(descendant::screen/userinput) &gt;
count(descendant::screen[@role='nodump'])">
<exsl:document href="{$dirname}/{$order}-{position()}-{$filename}"
method="text">
<xsl:text>#!/bin/bash
set +h
set -e
@ -252,7 +256,8 @@ set -e
cd $PKGDIR
</xsl:text>
<xsl:apply-templates
select=".//screen[not(@role) or @role != 'nodump']/userinput[@remap != 'adjust']"
select=".//screen[not(@role) or
@role != 'nodump']/userinput[@remap != 'adjust']"
mode="pkgmngt"/>
<xsl:if test="$dirname = 'chapter06'">
<xsl:text>packInstall
@ -260,11 +265,9 @@ rm -rf $PKG_DEST
</xsl:text>
</xsl:if>
<xsl:apply-templates
select=".//screen[
not(@role) or
select=".//screen[not(@role) or
@role != 'nodump'
]/userinput[
not(@remap) or
]/userinput[not(@remap) or
@remap='adjust'
]"
mode="pkgmngt"/>
@ -273,6 +276,7 @@ echo -e "\n\nTotalseconds: $SECONDS\n"
exit
</xsl:text>
</exsl:document>
</xsl:if>
</xsl:template>
<xsl:template match="userinput" mode="pkgmngt">