diff options
author | Pierre Labastie <pieere@linuxfromscratch.org> | 2020-03-13 09:20:45 +0000 |
---|---|---|
committer | Pierre Labastie <pieere@linuxfromscratch.org> | 2020-03-13 09:20:45 +0000 |
commit | 2e524f93fc03353e6fb05333d8041505948959eb (patch) | |
tree | 0e2f8a60e47c994d49152b300f0d698a7eb29c4f /stylesheets/lfs-xsl/docbook-xsl-1.78.1/website/makefile-dep.xsl | |
parent | cc98817b6165e5307c1fc38328cdc2a1cc2de257 (diff) |
Since LFS started using docbook-1.78.1, there is a lot of unused data
in the stylesheet directory. Basically, a whole docbook-stylesheet is
there, while we need only fo and xhtml (+ some common dirs). Each time
we checkout the repo, we have to download this whole thing, which is by
far the biggest part of the repo (~33 M). By removing unused cruft,
this could be down to ~12 M.
Of course, it would be even better to remove completely the stylesheets
and use host ones (repo size down to 2M). but let's do this first, it is
easier :)
git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@11778 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
Diffstat (limited to 'stylesheets/lfs-xsl/docbook-xsl-1.78.1/website/makefile-dep.xsl')
-rw-r--r-- | stylesheets/lfs-xsl/docbook-xsl-1.78.1/website/makefile-dep.xsl | 143 |
1 files changed, 0 insertions, 143 deletions
diff --git a/stylesheets/lfs-xsl/docbook-xsl-1.78.1/website/makefile-dep.xsl b/stylesheets/lfs-xsl/docbook-xsl-1.78.1/website/makefile-dep.xsl deleted file mode 100644 index 00f810b1d..000000000 --- a/stylesheets/lfs-xsl/docbook-xsl-1.78.1/website/makefile-dep.xsl +++ /dev/null @@ -1,143 +0,0 @@ -<?xml version="1.0"?> -<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" - version="1.0"> - -<xsl:param name="filename-prefix" select="''"/> -<xsl:param name="depends-file" select="''"/> -<xsl:param name="output-root" select="''"/> -<!-- Additional dependencies for target website --> -<xsl:param name="add-website-depends" select="''"/> -<!-- Remove output root dir instead removing each html output file. - Useful for removing subdirs and none html files: images, css etc. --> -<xsl:param name="remove-output-root" select="0"/> - -<xsl:output method="text"/> - -<xsl:template match="autolayout"> - <xsl:text>website: </xsl:text> - <xsl:value-of select="$add-website-depends"/> - <xsl:text> </xsl:text> - <xsl:apply-templates select="toc" mode="all"/> - <xsl:apply-templates select="notoc" mode="all"/> - <xsl:text> </xsl:text> - <xsl:apply-templates select="toc"/> - <xsl:apply-templates select="notoc"/> - <xsl:text> </xsl:text> - <xsl:text>distclean: clean -	-rm -f </xsl:text> - <xsl:text>autolayout.xml website.database.xml </xsl:text> - <xsl:text> </xsl:text> - <xsl:value-of select="$depends-file"/> - <xsl:text> </xsl:text> - <xsl:text>clean: </xsl:text> - <xsl:choose> - <xsl:when test="$remove-output-root and not($output-root='')"> - <xsl:text>	-rm -rf </xsl:text> - <xsl:call-template name="output-root"/> - </xsl:when> - <xsl:otherwise> - <xsl:text>	-rm -f </xsl:text> - <xsl:apply-templates select="toc" mode="all"/> - <xsl:apply-templates select="notoc" mode="all"/> - </xsl:otherwise> - </xsl:choose> - <xsl:text> </xsl:text> -</xsl:template> - -<xsl:template match="toc"> -<!-- - <xsl:apply-templates select="." mode="calculate-dir"/> ---> - <xsl:call-template name="output-root"/> - <xsl:value-of select="@dir"/> - <xsl:value-of select="$filename-prefix"/> - <xsl:value-of select="@filename"/> - <xsl:text>: </xsl:text> - <xsl:value-of select="@page"/> - <xsl:text> </xsl:text> - <xsl:apply-templates select=".//tocentry"/> -</xsl:template> - -<xsl:template match="tocentry|notoc"> -<!-- - <xsl:apply-templates select="." mode="calculate-dir"/> ---> - <xsl:if test="@filename"> - <xsl:call-template name="output-root"/> - <xsl:value-of select="@dir"/> - <xsl:value-of select="$filename-prefix"/> - <xsl:value-of select="@filename"/> - <xsl:text>: </xsl:text> - <xsl:value-of select="@page"/> - <xsl:text> </xsl:text> - </xsl:if> -</xsl:template> - -<xsl:template match="toc" mode="all"> - <xsl:apply-templates select=".//tocentry" mode="all"/> -<!-- - <xsl:apply-templates select="." mode="calculate-dir"/> ---> - <xsl:call-template name="output-root"/> - <xsl:value-of select="@dir"/> - <xsl:value-of select="$filename-prefix"/> - <xsl:value-of select="@filename"/> - <xsl:text> </xsl:text> -</xsl:template> - -<xsl:template match="tocentry|notoc" mode="all"> -<!-- - <xsl:apply-templates select="." mode="calculate-dir"/> ---> - <xsl:if test="@filename"> - <xsl:call-template name="output-root"/> - <xsl:value-of select="@dir"/> - <xsl:value-of select="$filename-prefix"/> - <xsl:value-of select="@filename"/> - <xsl:text> </xsl:text> - </xsl:if> -</xsl:template> - -<xsl:template match="*" mode="calculate-dir"> - <xsl:choose> - <xsl:when test="starts-with(@dir, '/')"> - <!-- if the directory on this begins with a "/", we're done... --> - <xsl:value-of select="substring-after(@dir, '/')"/> -<!-- - <xsl:if test="@dir != '/'"> - <xsl:text>/</xsl:text> - </xsl:if> ---> - </xsl:when> - - <xsl:when test="parent::*"> - <!-- if there's a parent, try it --> - <xsl:apply-templates select="parent::*" mode="calculate-dir"/> - <xsl:if test="@dir"> - <xsl:value-of select="@dir"/> -<!-- - <xsl:text>/</xsl:text> ---> - </xsl:if> - </xsl:when> - - <xsl:otherwise> - <xsl:if test="@dir"> - <xsl:value-of select="@dir"/> -<!-- - <xsl:text>/</xsl:text> ---> - </xsl:if> - </xsl:otherwise> - </xsl:choose> -</xsl:template> - -<xsl:template name="output-root"> - <xsl:if test="$output-root != ''"> - <xsl:value-of select="$output-root"/> - <xsl:text>/</xsl:text> - </xsl:if> -</xsl:template> - - -</xsl:stylesheet> |