1 ###############################################################################
2 # IPFire.org - An Open Source Firewall Solution #
3 # Copyright (C) - IPFire Development Team <info@ipfire.org> #
4 ###############################################################################
10 groups = Applications/Text
11 url = https://docbook.sourceforge.net/projects/xsl/
13 summary = Norman Walsh's XSL stylesheets for DocBook XML.
16 hese XSL stylesheets allow you to transform any DocBook XML document to
17 other formats, such as HTML, FO, and XHMTL. They are highly customizable.
20 source_dl = https://github.com/docbook/xslt10-stylesheets/releases/download/release/%{version}/
22 sources = %{thisapp}.tar.bz2
32 # Create directory layout.
33 mkdir -pv %{BUILDROOT}/%{datadir}/sgml/docbook/xsl-ns-stylesheets-%{version}
35 # Install catalog files.
36 cp -avf [[:lower:]]* %{BUILDROOT}/%{datadir}/sgml/docbook/xsl-ns-stylesheets-%{version}/
37 cp -avf VERSION %{BUILDROOT}/%{datadir}/sgml/docbook/xsl-ns-stylesheets-%{version}/VERSION.xsl
40 %{BUILDROOT}/%{datadir}/sgml/docbook/xsl-ns-stylesheets-%{version}/VERSION
41 ln -svf xsl-ns-stylesheets-%{version} \
42 %{BUILDROOT}/%{datadir}/sgml/docbook/xsl-ns-stylesheets
44 # Don't ship install shell script.
45 rm -rvf %{BUILDROOT}/%{datadir}/sgml/docbook/xsl-ns-stylesheets/install.sh
47 # Remove buggy extensions.
48 rm -rfv %{BUILDROOT}/%{datadir}/sgml/docbook/xsl-stylesheets-%{version}/extensions/*
50 # Remove unneeded tool for .epub formats.
51 rm -rvf %{BUILDROOT}/%{datadir}/sgml/docbook/xsl-stylesheets-%{version}/epub
53 # Fix directory permissions.
54 find %{BUILDROOT}%{datadir} -type d -exec chmod 755 {} \;
56 # Fix file permissions.
57 find %{BUILDROOT}%{datadir} -type f -exec chmod 644 {} \;
76 # Install catalog files.
77 /usr/bin/xmlcatalog --noout --add "rewriteSystem" \
78 "http://docbook.sourceforge.net/release/xsl/%{version}" \
79 "file:///usr/share/sgml/docbook/xsl-ns-stylesheets-%{version}" /etc/xml/catalog
81 /usr/bin/xmlcatalog --noout --add "rewriteURI" \
82 "http://docbook.sourceforge.net/release/xsl/%{version}" \
83 "file:///usr/share/sgml/docbook/xsl-ns-stylesheets-%{version}" /etc/xml/catalog
85 /usr/bin/xmlcatalog --noout --add "rewriteSystem" \
86 "http://docbook.sourceforge.net/release/xsl/current" \
87 "file:///usr/share/sgml/docbook/xsl-ns-stylesheets-%{version}" /etc/xml/catalog
89 /usr/bin/xmlcatalog --noout --add "rewriteURI" \
90 "http://docbook.sourceforge.net/release/xsl/current" \
91 "file:///usr/share/sgml/docbook/xsl-ns-stylesheets-%{version}" /etc/xml/catalog
93 /usr/bin/xmlcatalog --noout --add "rewriteSystem" \
94 "http://docbook.sourceforge.net/release/xsl-ns/current" \
95 "file:///usr/share/sgml/docbook/xsl-ns-stylesheets-%{version}" /etc/xml/catalog
97 /usr/bin/xmlcatalog --noout --add "rewriteURI" \
98 "http://docbook.sourceforge.net/release/xsl-ns/current" \
99 "file:///usr/share/sgml/docbook/xsl-ns-stylesheets-%{version}" /etc/xml/catalog
103 # Uninstall catalog files.
104 /usr/bin/xmlcatalog --noout --del \
105 "file:///usr/share/sgml/docbook/xsl-ns-stylesheets-%{version}" /etc/xml/catalog