all: titlepage.templates.xsl param.xsl
param.html: param.xml
+ ../../cvstools/paramchk -m Makefile.param $<
$(XSLT) $< ../docsrc/lrefentry.xsl $@
param.xml: param.xweb $(PARAMS)
$(XSLT) $< ../../litprog/wdocbook.xsl $@
param.xsl: param.xweb $(PARAMS)
+ ../../cvstools/paramchk -m Makefile.param $<
$(XSLT) $< ../../litprog/xtangle.xsl $@
titlepage.templates.xsl: titlepage.templates.xml ../template/titlepage.xsl
../params/chapter.autolabel.xml \
../params/chunk.datafile.xml \
../params/chunk.first.sections.xml \
- ../params/chunk.sections.xml \
+ ../params/chunk.section.depth.xml \
../params/citerefentry.link.xml \
../params/css.decoration.xml \
../params/default.encoding.xml \
<xsl:call-template name="process-chunk-element"/>
</xsl:template>
-<xsl:template match="sect1[$chunk.section.depth > 0]
- |sect2[$chunk.section.depth > 1]
- |sect3[$chunk.section.depth > 2]
- |sect4[$chunk.section.depth > 3]
- |sect5[$chunk.section.depth > 4]
- |section[$chunk.section.depth > count(ancestor::section)]
- |/section">
-
+<xsl:template match="sect1|sect2|sect3|sect4|sect5|section">
<xsl:variable name="ischunk">
<xsl:call-template name="chunk"/>
</xsl:variable>
<xsl:choose>
- <xsl:when test=". = /section">
+ <xsl:when test="not(parent::*)">
<xsl:call-template name="process-chunk-element"/>
</xsl:when>
<xsl:when test="$ischunk = 0">
<!ENTITY chapter.autolabel SYSTEM "../params/chapter.autolabel.xml">
<!ENTITY chunk.datafile SYSTEM "../params/chunk.datafile.xml">
<!ENTITY chunk.first.sections SYSTEM "../params/chunk.first.sections.xml">
-<!ENTITY chunk.sections SYSTEM "../params/chunk.sections.xml">
+<!ENTITY chunk.section.depth SYSTEM "../params/chunk.section.depth.xml">
<!ENTITY citerefentry.link SYSTEM "../params/citerefentry.link.xml">
<!ENTITY css.decoration SYSTEM "../params/css.decoration.xml">
<!ENTITY default.encoding SYSTEM "../params/default.encoding.xml">
<src:fragref linkend="chapter.autolabel.frag"/>
<src:fragref linkend="chunk.datafile.frag"/>
<src:fragref linkend="chunk.first.sections.frag"/>
-<src:fragref linkend="chunk.sections.frag"/>
+<src:fragref linkend="chunk.section.depth.frag"/>
<src:fragref linkend="citerefentry.link.frag"/>
<src:fragref linkend="css.decoration.frag"/>
<src:fragref linkend="default.encoding.frag"/>