Hello community,
here is the log from the commit of package docbook-xsl for openSUSE:Factory checked in at 2017-12-05 01:28:12
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/docbook-xsl (Old)
and /work/SRC/openSUSE:Factory/.docbook-xsl.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "docbook-xsl"
Tue Dec 5 01:28:12 2017 rev:1 rq:546168 version:1.79.2
Changes:
--------
New Changes file:
--- /dev/null 2017-10-14 16:26:57.428140955 +0200
+++ /work/SRC/openSUSE:Factory/.docbook-xsl.new/docbook-xsl.changes 2017-12-05 01:28:26.877200628 +0100
@@ -0,0 +1,808 @@
+-------------------------------------------------------------------
+Wed Nov 22 08:34:21 UTC 2017 - thomas.schraitle@suse.com
+
+- Abandom the docbook-xsl-stylesheets-script package.
+ The dbtoepub script is available from the rubygem-dbtoepub
+ package.
+ The script pdf2index is available in docbook-xsl-pdf2index
+
+-------------------------------------------------------------------
+Sun Nov 19 17:03:25 UTC 2017 - thomas.schraitle@suse.com
+
+- First attempt to build the two DocBook stylesheet packages
+ from a single source:
+ - Added xslnons-build script from upstream.
+ - Improved dbxslt-install.sh script a lot
+
+
+-------------------------------------------------------------------
+Tue Nov 14 12:44:15 UTC 2017 - thomas.schraitle@suse.com
+
+- Fix bsc#1063066:
+ From 1.79.1 and later, upstream decided to release namespace
+ aware stylesheets only. The non-NS stylesheets have to be built
+ with the "xslnons-build" script (taken from upstream).
+ This is integrated now.
+ The switch from NS-aware to non-NS stylesheets help to fix this
+ problem.
+
+-------------------------------------------------------------------
+Fri Oct 27 07:35:44 UTC 2017 - mpluskal@suse.com
+
+- Restore working patch (bsc#1063066):
+ * Rebase docbook-xsl-stylesheets-non-recursive_string_subst.patch
+
+-------------------------------------------------------------------
+Sun Oct 1 14:45:19 UTC 2017 - aavindraa@gmail.com
+
+- Update to version 1.79.2
+- Rebase docbook-xsl-stylesheets-non-recursive_string_subst.patch
+- callout-gen is removed
+
+-------------------------------------------------------------------
+Sat Aug 26 12:07:41 UTC 2017 - thomas.schraitle@suse.com
+
+- Add docbook-xsl-stylesheets-non-recursive_string_subst.patch
+ Use str:replace from exslt.org to implement string.subst
+
+ string.subst implementation causes recursion issues when building
+ systemd documentation. This issue has been reported in
+ https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=765567 and
+ https://bugs.archlinux.org/task/54694 .
+
+ Taken from https://github.com/fishilico/xslt10-stylesheets/commit/a7df4fbbef3ab0f97d50a...
+
+-------------------------------------------------------------------
+Tue Feb 7 16:40:58 UTC 2017 - dimstar@opensuse.org
+
+- Explicitly package %{_docdir}/%{name} to fix build with RPM 4.13.
+
+-------------------------------------------------------------------
+Tue Jul 19 11:44:56 UTC 2016 - fvogt@suse.com
+
+- Use update-xml-catalog
+
+-------------------------------------------------------------------
+Mon Dec 21 09:44:33 UTC 2015 - mpluskal@suse.com
+
+- Update download urls
+
+-------------------------------------------------------------------
+Sat Dec 12 18:35:36 UTC 2015 - p.drouand@gmail.com
+
+- Update to version 1.79.0, see
+ http://snapshots.docbook.org/xsl/RELEASE-NOTES.html#V1.79.0
+ for details (Mostly bugfix release)
+- Remove obsolete patches
+ * docbook-xsl-stylesheets-epub3-base.dir.patch
+ * docbook-xsl-stylesheets-manpages-other-r9847.patch
+- Perform a spec-cleaner on the spec file
+
+-------------------------------------------------------------------
+Wed Apr 29 09:38:13 UTC 2015 - toms@opensuse.org
+
+- Fixed bsc#928753 (added missing template directory)
+- Slightly corrected file list
+
+-------------------------------------------------------------------
+Thu Feb 19 12:25:28 UTC 2015 - toms@opensuse.org
+
+- Slightly adapted %post and %postun section to fix bsc#918565
+
+-------------------------------------------------------------------
+Mon Jan 12 09:53:49 UTC 2015 - fsundermeyer@opensuse.org
+
+- Added missing images directory to install-script dbxslt-install.sh
+
+-------------------------------------------------------------------
+Thu Feb 6 13:30:10 UTC 2014 - toms@opensuse.org
+
+- Fixed bnc#842844 and added upstream patch from r9847 of docbook#1313
+ (File docbook-xsl-stylesheets-manpages-other-r9847.patch)
+
+-------------------------------------------------------------------
+Thu Feb 6 12:03:53 UTC 2014 - ke@suse.com
+
+- .spec: syntax fix.
+
+-------------------------------------------------------------------
+Mon Dec 9 13:49:49 UTC 2013 - toms@opensuse.org
+
+- Added missing patch description to follow Patch Guidlines
+ (see http://en.opensuse.org/openSUSE:Packaging_Patches_guidelines)
+- Added upstream patch (r9732-r9743 for base.dir parameter in EPUB3)
+
+-------------------------------------------------------------------
+Mon Sep 23 13:51:41 UTC 2013 - toms@opensuse.org
+
+- Moved installation procedure into dbxslt-install.sh Shell script
+
+-------------------------------------------------------------------
+Fri Jun 28 09:12:59 UTC 2013 - toms@opensuse.org
+
+- Corrected conflict with docbook5-xsl-stylesheets:
+ Created subpackage with pdf2index (which raised this conflict)
+ and moved other scripts too (db2epub, callout-gen).
+ This makes it easier to install both variantes of the
+ stylesheets
+
+-------------------------------------------------------------------
+Fri May 31 16:03:17 UTC 2013 - varkoly@suse.com
+
+- Fix spec to avoid conflict with docbook5-xsl-stylesheets
+
+-------------------------------------------------------------------
+Mon Mar 18 09:42:59 UTC 2013 - toms@opensuse.org
+
+- Update to 1.78.1, see http://snapshots.docbook.org/xsl/RELEASE-NOTES.html#V1.78.1
+ for details
+- Added %exclude in SPEC file for .htaccess files
+
+-------------------------------------------------------------------
+Thu Jan 17 19:41:11 UTC 2013 - p.drouand@gmail.com
+
+- Updated to 1.78.0, see http://snapshots.docbook.org/xsl/RELEASE-NOTES.html#V1.78.0
+ for details (Mostly bugfix release)
+
+-------------------------------------------------------------------
+Mon Jun 11 13:13:30 UTC 2012 - toms@opensuse.org
+
+- Fixed SPEC file:
+ * added missing db2epub in /epub/bin/
+ * create symbolic links (-s) with fdupes
+
+-------------------------------------------------------------------
+Tue Jun 5 09:57:35 UTC 2012 - toms@opensuse.org
+
+- Updated to 1.77.1, see http://snapshots.docbook.org/xsl/RELEASE-NOTES.html#V1.77.1
+ for details (Mostly bugfix release)
+- Fixed spec file to copy VERSION.xsl instead of VERSION
+
+-------------------------------------------------------------------
+Fri May 25 08:53:52 UTC 2012 - toms@opensuse.org
+
+- Updated to 1.77.0, see http://snapshots.docbook.org/xsl/RELEASE-NOTES.html#V1.77.0
+ for details
+ (Merged from Factory)
+
+-------------------------------------------------------------------
+Thu Jan 12 11:30:33 UTC 2012 - coolo@suse.com
+
+- change license to be in spdx.org format
+
+-------------------------------------------------------------------
+Wed Sep 21 10:32:26 UTC 2011 - coolo@suse.com
+
+- remove ruby requires, there is nothing in here using ruby and
+ ruby needs this package indirectly - creating a build cycle
+
+-------------------------------------------------------------------
+Sun Sep 18 17:17:12 UTC 2011 - jengelh@medozas.de
+
+- Remove redundant tags/sections from specfile
+ (cf. packaging guidelines)
+
+-------------------------------------------------------------------
+Tue Apr 12 06:30:39 UTC 2011 - toms@suse.de
+
+- Update to 1.76.1; for news, see
+ http://lists.oasis-open.org/archives/docbook-apps/201011/msg00007.html
+- Moved pdf2index and dbtoepub to /usr/bin
+- Cleaned up Spec file to avoid rpmlint warnings
+- Removed now obsolete chunktoc-fix.patch
+
+-------------------------------------------------------------------
+Wed Apr 14 12:28:37 CEST 2010 - mmarek@suse.cz
+
+- chunktoc.xsl: Added missing namespace declarations. Closes
++++ 611 more lines (skipped)
++++ between /dev/null
++++ and /work/SRC/openSUSE:Factory/.docbook-xsl.new/docbook-xsl.changes
New:
----
dbxslt-install.sh
docbook-xsl-1.79.2.tar.bz2
docbook-xsl-dbtoepub.patch
docbook-xsl-doc-1.79.2.tar.bz2
docbook-xsl-non-recursive_string_subst.patch
docbook-xsl-stylesheets.xml
docbook-xsl.changes
docbook-xsl.spec
docbook5-xsl-stylesheets.xml
xslnons-build
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ docbook-xsl.spec ++++++
#
# spec file for package docbook-xsl
#
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%define realversion %{version}
#
%define db4rootdir %{_datadir}/xml/docbook/stylesheet/nwalsh
%define db4package docbook-xsl-stylesheets
%define db4style_catalog %{db4package}.xml
#
%define db5rootdir %{_datadir}/xml/docbook/stylesheet/nwalsh5
%define db5package docbook5-xsl-stylesheets
%define db5style_catalog %{db5package}.xml
#
%define etcxmlcatalogd %{_sysconfdir}/xml/catalog.d
#
Name: docbook-xsl
Version: 1.79.2
Release: 0
Summary: XSL Stylesheets for DocBook
License: MPL-1.1 AND MIT
Group: Productivity/Publishing/DocBook
URL: https://github.com/docbook/xslt10-stylesheets
Source0: https://github.com/docbook/xslt10-stylesheets/releases/download/release%%2F%{version}/docbook-xsl-%{version}.tar.bz2
Source1: https://github.com/docbook/xslt10-stylesheets/releases/download/release%%2F%{version}/docbook-xsl-doc-%{version}.tar.bz2
Source2: %{db4style_catalog}
Source3: %{db5style_catalog}
# Build scripts
Source10: dbxslt-install.sh
Source11: xslnons-build
## PATCH-FIX-OPENSUSE docbook-xsl-stylesheets-dbtoepub.patch Fixed dirname
Patch0: %{name}-dbtoepub.patch
## PATCH-FIX-OPENSUSE docbook-xsl-stylesheets-non-recursive_string_subst.patch Use EXSLT replace function to avoid recursive implementation of string.subst
Patch1: %{name}-non-recursive_string_subst.patch
BuildRequires: fdupes
BuildRequires: sgml-skel >= 0.7
BuildRequires: unzip
Requires: docbook_4
Requires: sgml-skel >= 0.7
Requires: xmlcharent
Requires(post): sgml-skel >= 0.7
Requires(postun): sgml-skel >= 0.7
Requires(pre): %{_bindir}/xmlcatalog
BuildArch: noarch
#--------------------------------------------------------------------------
%description
%{summary}.
Wrapper package for DocBook 4 and 5 stylesheets.
%package -n %{db4package}
Summary: XSL Stylesheets for DocBook 4
Group: Productivity/Publishing/XML
Requires: docbook_4
Requires: sgml-skel >= 0.7
Requires: xmlcharent
Requires(post): sgml-skel >= 0.7
Requires(postun): sgml-skel >= 0.7
Suggests: rubygem(dbtoepub)
%description -n %{db4package}
These are the XSL stylesheets for DocBook XML and "Simplified" DocBook
DTDs. Use these stylesheets for documents based on DocBook 4 and
earlier; they are not aware of the namespace feature.
The stylesheets transform DocBook 4 documents into HTML, XHTML, Manpages,
XSL-FO (for PDF), and a few other formats.
XSL is a standard W3C stylesheet language for both print and online
rendering. For more information about XSL, see the XSL page at the W3C:
http://www.w3.org/Style/XSL/
%package -n docbook5-xsl-stylesheets
Summary: XSL Stylesheets for DocBook 5
Group: Productivity/Publishing/XML
Requires: docbook_5
Requires: sgml-skel >= 0.7
Requires: xmlcharent
Requires(post): sgml-skel >= 0.7
Requires(postun): sgml-skel >= 0.7
Suggests: rubygem(dbtoepub)
%description -n docbook5-xsl-stylesheets
These are the XSL stylesheets for DocBook 5 XML and "Simplified" DocBook 5.
Use these stylesheets for documents based on DocBook 5; they are aware
of the namespace feature.
The stylesheets transform DocBook 5 documents into HTML, XHTML, Manpages,
XSL-FO (for PDF), and a few other formats.
XSL is a standard W3C stylesheet language for both print and online
rendering. For more information about XSL, see the XSL page at the W3C:
http://www.w3.org/Style/XSL/
%package pdf2index
# License: MPL-1.1 and MIT
Summary: Script to create Indices for FOP
Group: Productivity/Publishing/XML
Requires: ImageMagick
Requires: perl
%description pdf2index
Contains the script pdf2index which creates indices for FOP.
%prep
# %%setup -q -n docbook-xsl-%%{realversion} -b1
%setup -q -c -T -n docbook-xsl
# Prepare directories:
mkdir docbook-xsl-%{realversion}-ns docbook-xsl-%{realversion}-nons
# Copy all source files and make scripts executable:
cp %{SOURCE2} %{SOURCE3} %{SOURCE10} %{SOURCE11} .
chmod +x $(basename %{SOURCE10}) $(basename %{SOURCE11})
# Replace version in XML catalog files
db4=$(basename %{SOURCE2})
db5=$(basename %{SOURCE3})
sed --in-place 's/@VERSION@/%{realversion}/' $db4
sed --in-place 's/@VERSION@/%{realversion}/' $db5
# Unpack stylesheet and doc sources into the correct directory:
tar xf %{SOURCE0} -C docbook-xsl-%{realversion}-ns --strip-components 1
tar xf %{SOURCE1} -C docbook-xsl-%{realversion}-ns --strip-components 1
# Patch the orginal source and remove unnecessary files:
(cd docbook-xsl-%{realversion}-ns
%patch0 -p1
%patch1 -p1
# Remove some Python and Java extensions
# Remove dbtoepub Ruby script. This has been moved to devel:languages:ruby:extensions
# see rubygem-dbtoepub
rm -rf extensions/*.py extensions/saxon65.jar extensions/xalan27.jar \
extensions/build.xml epub/bin
)
%build
pushd docbook-xsl-%{realversion}-ns
find slides -regex ".*\.\(xml\|htc\|\|hu\|js\|svg\|css\|html\.*\|txt\|rnc\|xhtml\)" \
-exec sed -i 's/\r//' {} \;
# Fix wrong end-of-line encoding:
sed -i 's/\r//' params/*
# Correct file and directory properties:
find -type f -exec chmod 644 {} \;
find -type d -exec chmod 755 {} \;
# Remove any .htaccess files:
find -type f -name "\.htaccess" -exec rm {} \;
popd
# Create the non-NS variant from the NS original source:
./xslnons-build docbook-xsl-%{realversion}-ns docbook-xsl-%{realversion}-nons
%install
mkdir -p %{buildroot}%{_sysconfdir}/xml/catalog.d \
%{buildroot}%rb_libdir/
./dbxslt-install.sh --debug --buildroot=%{buildroot} \
--package-version=%{realversion} \
--package-name=%{db4package} \
--sourcedir=docbook-xsl-%{realversion}-nons
./dbxslt-install.sh --debug --buildroot=%{buildroot} \
--package-version=%{realversion} \
--package-name=%{db5package} \
--db-xsl-suffix=nwalsh5 \
--sourcedir=docbook-xsl-%{realversion}-ns
# The directory is already available at this point:
install -m644 %{db4style_catalog} %{db5style_catalog} %{buildroot}%{etcxmlcatalogd}
%fdupes -s %{buildroot}
%post -n %{db4package}
update-xml-catalog
%postun -n %{db4package}
update-xml-catalog
%post -n %{db5package}
update-xml-catalog
%postun -n %{db5package}
update-xml-catalog
%files -n %{db4package}
%config %{_sysconfdir}/xml/catalog.d/%{db4style_catalog}
%doc docbook-xsl-%{realversion}-nons/BUGS docbook-xsl-%{realversion}-nons/NEWS
%doc docbook-xsl-%{realversion}-nons/README docbook-xsl-%{realversion}-nons/RELEASE-NOTES.*
%doc docbook-xsl-%{realversion}-nons/TODO
%dir %{_datadir}/xml/docbook/stylesheet
%dir %{db4rootdir}
%dir %{db4rootdir}/%{realversion}
%exclude %{db4rootdir}/%{realversion}/fo/pdf2index
%{db4rootdir}/current
%{db4rootdir}/%{realversion}/*
%files -n %{db5package}
%config %{_sysconfdir}/xml/catalog.d/%{db5style_catalog}
%doc docbook-xsl-%{realversion}-ns/BUGS docbook-xsl-%{realversion}-ns/NEWS
%doc docbook-xsl-%{realversion}-ns/README docbook-xsl-%{realversion}-ns/RELEASE-NOTES.*
%doc docbook-xsl-%{realversion}-ns/TODO
%dir %{_datadir}/xml/docbook/stylesheet
%dir %{db5rootdir}
%dir %{db5rootdir}/%{realversion}
%exclude %{db5rootdir}/%{realversion}/fo/pdf2index
%{db5rootdir}/current
%{db5rootdir}/%{realversion}/*
%files pdf2index
%attr(0755,root,root) %{_bindir}/pdf2index
%changelog
++++++ dbxslt-install.sh ++++++
#!/bin/bash
#
# Installs the DocBook XSL Stylesheets on openSUSE systems
#
# Author: Thomas Schraitle
# Copyright 2016-2017 toms@opensuse.org
#
# set -x
ME=${0##*/}
#
PACKAGE=docbook-xsl-stylesheets
PACKAGE_VERSION=
SOURCEDIR=
#----------------------------------------------------------------------
# System variables
BUILDROOT=
PREFIX=/usr
BINDIR=$PREFIX/bin
DATADIR=share
DOCDIR=$DATADIR/doc/packages
SYSCONFDIR=/etc
XMLCONFDIR=$SYSCONFDIR/xml
XMLDIR=$DATADIR/xml
XMLCATALOGDIR=$XMLCONFDIR/catalog.d
DBSTYLE_CATALOG=$XMLCATALOGDIR/$PACKAGE.xml
DB_XSL_ROOTDIR=$XMLDIR/docbook/stylesheet
DB_XSL_SUFFIX=nwalsh
DBSTYLE_DIR=$DB_XSL_ROOTDIR/$DB_XSL_SUFFIX
SYS_DBSTYLE_DIR=$PREFIX/$DBSTYLE_DIR
INSTALL_SCRIPTS=0
function exit_on_error() {
local result
result=${2:-1}
echo "ERROR: ${1}" >&2
exit $result;
}
function my_debug() {
# Syntax: my_debug "MESSAGE" [MORE ARGUMENTS...]
# Prints debug messages, if DEBUG_SCRIPT is non-empty
if [[ "$DEBUG_SCRIPT" ]]; then
echo -n -e "[debug] ${ME}: $@\n" >&2;
fi
}
function usage() {
cat << EOF
Installs the DocBook XSL Stylesheets
Usage:
$ME [OPTIONS]
Fine tuning of the installation directories:
--buildroot=DIR build root directory []
--prefix=DIR [${PREFIX}]
--bindir=DIR user executables [${BINDIR}]
--sysconfdir=DIR read-only single-machine data [${SYSCONFDIR}]
--datarootdir=DIR read-only arch.-independent data root [PREFIX/DATADIR]
--datadir=DIR read-only architecture-independent data [${DATADIR}]
--docdir=DIR documentation root [PREFIX/${DOCDIR}]
--catalog-dir=DIR XML catalog directory to store all catalog files [${XMLCATALOGDIR}]
--db-xsl-suffix=SUFFIX the suffix that is appended to the DocBook stylesheet dir [${DB_XSL_SUFFIX}]
--db-xslt-dir=DIR root directory for DocBook stylesheets (without version)
[DATADIR/xml/docbook/stylesheet/DB_XSL_SUFFIX]
Behaviour
--skip-install-scripts Do not install any scripts [False]
Source package options:
--sourcedir=NAME directory of source directory
--package-name=NAME name of the package [$PACKAGE]
--package-version=VERSION version of the package [$PACKAGE_VERSION]
EOF
}
function printvariables() {
my_debug "Currently set variables:"
cat << EOF
package=$PACKAGE
package-version=$PACKAGE_VERSION
sourcedir=$SOURCEDIR
buildroot=$BUILDROOT
prefix=$PREFIX
bindir=$BINDIR
datadir=$DATADIR
docdir=$DOCDIR
xmldir=$XMLDIR
xsltrootdir=$XSLTROOTDIR
dbstyle_dir=$DBSTYLE_DIR
db_xsl_suffix=$DB_XSL_SUFFIX
#
sysconfdir=$SYSCONFDIR
xmlconfdir=$XMLCONFDIR
xmlcatalogdir=$XMLCATALOGDIR
dbstyle_catalog=$DBSTYLE_CATALOG
EOF
}
#----------------------------------------------------------------------
#
DEBUG_SCRIPT=
# Source Installation directories:
DBXSLT_DIRS="assembly common eclipse epub epub3 extensions fo \
images highlighting html htmlhelp lib javahelp manpages params \
profiling roundtrip slides template webhelp website xhtml xhtml-1_1 xhtml5"
# Without catalog.xml
DBXSLT_FILES="VERSION VERSION.xsl"
# Without INSTALL
DBXSLT_DOCFILES="AUTHORS BUGS COPYING NEWS.html NEWS.xml README TODO \
RELEASE-NOTES.html RELEASE-NOTES.pdf RELEASE-NOTES.txt RELEASE-NOTES.xml"
#----------------------------------------------------------------------
# printing help / catching errors
#
if [[ -z "$1" ]]; then
usage
printvariables
exit
fi
# datarootdir:,
longopt="help,debug,buildroot:,sourcedir:,\
package-name:,package-version:,\
bindir:,prefix:,datadir:,docdir:,sysconfdir:,\
skip-install-scripts,\
db-xslt-dir:,db-xsl-suffix:,catalog-dir:"
export POSIXLY_CORRECT=1
ARGS=$(getopt -o h,d -l $longopt -n $ME -- "$@")
eval set -- "$ARGS"
while true ; do
case "$1" in
-h|--help)
usage
# printvariables
exit
;;
-d|--debug)
DEBUG_SCRIPT=1
shift
;;
#
--sourcedir)
SOURCEDIR=$2
shift 2
;;
#
--package-name)
PACKAGE=$2
shift 2
;;
#
--package-version)
PACKAGE_VERSION="$2"
shift 2
;;
#
--buildroot)
BUILDROOT=$2
shift 2
;;
--bindir)
BINDIR=$2
shift 2
;;
--prefix)
PREFIX=$2
shift 2
;;
#--datarootdir)
# DATAROOTDIR=$2
# shift 2
# ;;
--datadir)
DATADIR=$2
shift 2
;;
--docdir)
DOCDIR=$2
shift 2
;;
--sysconfdir)
SYSCONFDIR=$2
shift 2
;;
#
--catalog-dir)
XMLCATALOGDIR=$2
shift 2
;;
#
--db-xslt-dir)
DBSTYLE_DIR=$2
shift 2
;;
#
--db-xsl-suffix)
DB_XSL_SUFFIX=$2
echo ">>>> $2"
shift 2
;;
--printvariables)
printvariables
exit 1
;;
#
--skip-install-scripts)
INSTALL_SCRIPTS=1
shift
;;
--)
break
;;
esac
done
unset POSIXLY_CORRECT
PREFIX=$BUILDROOT$PREFIX
BINDIR=$BUILDROOT$BINDIR
DATADIR=$PREFIX/$DATADIR
DOCDIR=$PREFIX/$DOCDIR
XMLDIR=$PREFIX/$XMLDIR
XSLTROOTDIR=$PREFIX$XSLTROOTDIR
DBSTYLE_DIR=$PREFIX/$DB_XSL_ROOTDIR/$DB_XSL_SUFFIX
#
SYSCONFDIR=$BUILDROOT$SYSCONFDIR
XMLCONFDIR=$BUILDROOT$XMLCONFDIR
XMLCATALOGDIR=$BUILDROOT$XMLCATALOGDIR
# DBSTYLE_CATALOG=$BUILDROOT$DBSTYLE_CATALOG
DBSTYLE_CATALOG=$XMLCATALOGDIR/$PACKAGE.xml
printvariables
# exit 1
# Consistency check
[[ -z $SOURCEDIR ]] && exit_on_error "Source directory not set. Use --sourcedir DIRECTORY"
# exit 100
#----------------------------------------------------------------------
#
#
function create_directory_structure() {
local i
my_debug "\n\n=== Create directory structure ==="
for i in $PREFIX $BINDIR $DATADIR $XMLCATALOGDIR \
$DOCDIR/$PACKAGE/html $DBSTYLE_DIR/$PACKAGE_VERSION; do
mkdir ${DEBUG_SCRIPT:+-v} -p $i
[[ $? -ne 0 ]] && exit_on_error "Could not create $i directory"
done
}
#----------------------------------------------------------------------
#
#
function install_dbxsltdirs() {
my_debug "\n\n=== Install all DocBook XSL stylesheet directories ==="
for dir in $DBXSLT_DIRS; do
my_debug "Copy directory $dir..."
cp -a $SOURCEDIR/$dir $DBSTYLE_DIR/$PACKAGE_VERSION
done
}
function install_scripts() {
my_debug "\n\n=== Install scripts ==="
install ${DEBUG_SCRIPT:+-v} -m755 $SOURCEDIR/fo/pdf2index $BINDIR
install ${DEBUG_SCRIPT:+-v} -m755 $SOURCEDIR/epub/bin/dbtoepub $BINDIR
# install ${DEBUG_SCRIPT:+-v} -m755 $SOURCEDIR/slides/images/callouts/gen.sh $BINDIR/callout-gen
# rm fo/pdf2index epub/bin/dbtoepub slides/images/callouts/gen.sh
}
function install_dbxsltfiles() {
my_debug "\n\n=== Install other files ==="
for file in $DBXSLT_FILES; do
my_debug "Copy $file..."
cp -a $SOURCEDIR/$file $DBSTYLE_DIR/$PACKAGE_VERSION
done
}
function install_dbxsltdocfiles() {
my_debug "\n\n=== Install documentation ==="
my_debug " Current dir: $PWD"
for file in $DBXSLT_DOCFILES; do
cp ${DEBUG_SCRIPT:+-v} $SOURCEDIR/$file $DOCDIR/$PACKAGE
# $DBSTYLE_DIR/$PACKAGE_VERSION
done
}
function create_link() {
my_debug "\n\n=== Create link ==="
pushd $DBSTYLE_DIR
ln ${DEBUG_SCRIPT:+-v} -s ${PACKAGE_VERSION} current
popd
}
function create_dbxslt_catalog() {
my_debug "\n\n=== Create catalog file ==="
# /etc/xml/catalog.d/docbook-xsl-stylesheets.xml
xmlcatalog --noout --create $DBSTYLE_CATALOG
}
function create_dbxslt_addentries() {
my_debug "\n\n=== Create entries in the catalog file ==="
DBSTYLE_DIR=$DB_XSL_ROOTDIR/$DB_XSL_SUFFIX
# Don't be confused, see docbook-apps mailinglist
local CDN4_XSL_URL="http://cdn.docbook.org/release/xsl-nons"
local CDN5_XSL_URL="http://cdn.docbook.org/release/xsl"
local DB4_XSL_URL="http://docbook.sourceforge.net/release/xsl/"
local DB5_XSL_URL="http://docbook.sourceforge.net/release/xsl-ns/"
local CDN_XSL_URL DB_XSL_URL
CDN_XSL_URL=$CDN4_XSL_URL
DB_XSL_URL=$DB4_XSL_URL
# This is flaky and not ideal. :-(
if [[ $DB_XSL_SUFFIX = "nwalsh5" ]]; then
CDN_XSL_URL=$CDN5_XSL_URL
DB_XSL_URL=$DB5_XSL_URL
fi
my_debug "Using URL=${DB_XSL_URL}"
my_debug "Using URL=${CDN_XSL_URL}"
my_debug "Using system path=${DBSTYLE_DIR}"
# Create first the old DocBook SF identifiers:
xmlcatalog --noout --add "rewriteSystem" \
"${DB_XSL_URL}${PACKAGE_VERSION}" \
"file://$SYS_DBSTYLE_DIR/${PACKAGE_VERSION}" $DBSTYLE_CATALOG
xmlcatalog --noout --add "rewriteURI" \
"${DB_XSL_URL}${PACKAGE_VERSION}" \
"file://$SYS_DBSTYLE_DIR/$PACKAGE_VERSION" $DBSTYLE_CATALOG
xmlcatalog --noout --add "rewriteSystem" \
"${DB_XSL_URL}current" \
"file://$SYS_DBSTYLE_DIR/current" $DBSTYLE_CATALOG
xmlcatalog --noout --add "rewriteURI" \
"${DB_XSL_URL}current" \
"file://$SYS_DBSTYLE_DIR/current" $DBSTYLE_CATALOG
# Create the new DocBook XSL identifier:
xmlcatalog --noout --add "rewriteURI" \
"${CDN_XSL_URL}/${PACKAGE_VERSION}" \
"file://$SYS_DBSTYLE_DIR/${PACKAGE_VERSION}" $DBSTYLE_CATALOG
xmlcatalog --noout --add "rewriteSystem" \
"${CDN_XSL_URL}/${PACKAGE_VERSION}" \
"file://$SYS_DBSTYLE_DIR/${PACKAGE_VERSION}" $DBSTYLE_CATALOG
xmlcatalog --noout --add "rewriteURI" \
"${CDN_XSL_URL}/current" \
"file://$SYS_DBSTYLE_DIR/current" $DBSTYLE_CATALOG
xmlcatalog --noout --add "rewriteSystem" \
"${CDN_XSL_URL}/current" \
"file://$SYS_DBSTYLE_DIR/current" $DBSTYLE_CATALOG
}
function cleanup_buildroot() {
rm $DBSTYLE_DIR/$PACKAGE_VERSION/fo/pdf2index \
$DBSTYLE_DIR/$PACKAGE_VERSION/epub/bin/dbtoepub \
$DBSTYLE_DIR/$PACKAGE_VERSION/slides/images/callouts/gen.sh
}
#----------------------------------------------------------------------
# MAIN
#
[[ -e "$SOURCEDIR" ]] || exit_on_error "Could not find directory $SOURCEDIR"
#
#
create_directory_structure
install_dbxsltdirs
install_dbxsltfiles
[[ 0 -eq $INSTALL_SCRIPTS ]] && install_scripts
# install_dbxsltdocfiles
create_link
#
# create_dbxslt_catalog
# create_dbxslt_addentries
# cleanup_buildroot
my_debug "\n\n=== Finished script."
# EOF
++++++ docbook-xsl-dbtoepub.patch ++++++
diff -ur docbook-xsl-1.76.1.orig/epub/bin/dbtoepub docbook-xsl-1.76.1/epub/bin/dbtoepub
--- docbook-xsl-1.76.1.orig/epub/bin/dbtoepub 2010-09-13 23:59:41.000000000 +0200
+++ docbook-xsl-1.76.1/epub/bin/dbtoepub 2011-04-12 09:43:49.000000000 +0200
@@ -17,7 +17,7 @@
# layer (imports epub/docbook.xsl).
# -v, --verbose Make output verbose.
-lib = File.expand_path(File.join(File.dirname(__FILE__), 'lib'))
+lib= '/usr/share/xml/docbook/stylesheet/nwalsh/current/epub/bin/lib'
$LOAD_PATH.unshift(lib) if File.exist?(lib)
require 'fileutils'
Nur in docbook-xsl-1.76.1/epub/bin: dbtoepub~.
++++++ docbook-xsl-non-recursive_string_subst.patch ++++++
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