Commit db96c831 authored by Vladimir Bashkirtsev's avatar Vladimir Bashkirtsev

Initial commit

parents
all:
tar xf docbook-xsl-1.79.2.tar.bz2
patch -Np1 -d docbook-xsl-1.79.2 < docbook-xsl-1.79.2-stack_fix-1.patch
install -v -m755 -d /usr/share/xml/docbook/xsl-stylesheets-1.79.2
cd docbook-xsl-1.79.2 && cp -v -R VERSION assembly common eclipse epub epub3 extensions fo highlighting html htmlhelp images javahelp lib manpages params profiling roundtrip slides template tests tools webhelp website xhtml xhtml-1_1 xhtml5 /usr/share/xml/docbook/xsl-stylesheets-1.79.2
ln -s VERSION /usr/share/xml/docbook/xsl-stylesheets-1.79.2/VERSION.xsl
cd docbook-xsl-1.79.2 && install -v -m644 -D README /usr/share/doc/docbook-xsl-1.79.2/README.txt
cd docbook-xsl-1.79.2 && install -v -m644 RELEASE-NOTES* NEWS* /usr/share/doc/docbook-xsl-1.79.2
if [ ! -d /etc/xml ]; then \
install -v -m755 -d /etc/xml ; \
fi
if [ ! -f /etc/xml/catalog ]; then \
xmlcatalog --noout --create /etc/xml/catalog ; \
fi
xmlcatalog --noout --add "rewriteSystem" "http://docbook.sourceforge.net/release/xsl/1.79.2" "/usr/share/xml/docbook/xsl-stylesheets-1.79.2" /etc/xml/catalog
xmlcatalog --noout --add "rewriteURI" "http://docbook.sourceforge.net/release/xsl/1.79.2" "/usr/share/xml/docbook/xsl-stylesheets-1.79.2" /etc/xml/catalog
xmlcatalog --noout --add "rewriteSystem" "http://docbook.sourceforge.net/release/xsl/current" "/usr/share/xml/docbook/xsl-stylesheets-1.79.2" /etc/xml/catalog
xmlcatalog --noout --add "rewriteURI" "http://docbook.sourceforge.net/release/xsl/current" "/usr/share/xml/docbook/xsl-stylesheets-1.79.2" /etc/xml/catalog
rm -rf docbook-xsl-1.79.2
Submitted By: Bruce Dubbs <bdubbs at linuxfromscratch dot org>
Date: 2018-01-01
Initial Package Version: 1.78.1
Upstream Status: Unsure
Origin: Peter De Wachter <pdewacht@gmail.com>
Description: use EXSLT "replace" function when available
A recursive implementation of string.subst is problematic,
long strings with many matches will cause stack overflows.
Author: Peter De Wachter <pdewacht@gmail.com>
Bug-Debian: https://bugs.debian.org/750593
Rediffed for 1.79.2 by Bruce Dubbs
diff -Naur docbook-xsl-1.79.2.orig/lib/lib.xsl docbook-xsl-1.79.2/lib/lib.xsl
--- docbook-xsl-1.79.2.orig/lib/lib.xsl 2016-12-09 16:41:39.000000000 -0600
+++ docbook-xsl-1.79.2/lib/lib.xsl 2018-01-01 12:54:52.507332514 -0600
@@ -6,7 +6,11 @@
This module implements DTD-independent functions
- ******************************************************************** --><xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
+ ******************************************************************** -->
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:str="http://exslt.org/strings"
+ exclude-result-prefixes="str"
+ version="1.0">
<xsl:template name="dot.count">
<!-- Returns the number of "." characters in a string -->
@@ -52,6 +56,9 @@
<xsl:param name="replacement"/>
<xsl:choose>
+ <xsl:when test="function-available('str:replace')">
+ <xsl:value-of select="str:replace($string, string($target), string($replacement))"/>
+ </xsl:when>
<xsl:when test="contains($string, $target)">
<xsl:variable name="rest">
<xsl:call-template name="string.subst">
doc
/usr/share/doc/.*
xml
/usr/share/xml/.*
etc
/etc/.*
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment