[arch-commits] Commit in docbook-xml/repos (4 files)
Jan Steffens
heftig at archlinux.org
Wed Sep 19 20:48:37 UTC 2018
Date: Wednesday, September 19, 2018 @ 20:48:37
Author: heftig
Revision: 335027
archrelease: copy trunk to testing-any
Added:
docbook-xml/repos/testing-any/
docbook-xml/repos/testing-any/LICENSE
(from rev 335026, docbook-xml/trunk/LICENSE)
docbook-xml/repos/testing-any/PKGBUILD
(from rev 335026, docbook-xml/trunk/PKGBUILD)
docbook-xml/repos/testing-any/docbook-xml.install
(from rev 335026, docbook-xml/trunk/docbook-xml.install)
---------------------+
LICENSE | 24 ++++++++++
PKGBUILD | 114 ++++++++++++++++++++++++++++++++++++++++++++++++++
docbook-xml.install | 42 ++++++++++++++++++
3 files changed, 180 insertions(+)
Copied: docbook-xml/repos/testing-any/LICENSE (from rev 335026, docbook-xml/trunk/LICENSE)
===================================================================
--- testing-any/LICENSE (rev 0)
+++ testing-any/LICENSE 2018-09-19 20:48:37 UTC (rev 335027)
@@ -0,0 +1,24 @@
+ Copyright 1992-2006 HaL Computer Systems, Inc.,
+ O'Reilly & Associates, Inc., ArborText, Inc., Fujitsu Software
+ Corporation, Norman Walsh, Sun Microsystems, Inc., and the
+ Organization for the Advancement of Structured Information
+ Standards (OASIS).
+
+ See also http://docbook.org/specs/
+
+ Permission to use, copy, modify and distribute the DocBook XML DTD
+ and its accompanying documentation for any purpose and without fee
+ is hereby granted in perpetuity, provided that the above copyright
+ notice and this paragraph appear in all copies. The copyright
+ holders make no representation about the suitability of the DTD for
+ any purpose. It is provided "as is" without expressed or implied
+ warranty.
+
+ If you modify the DocBook DTD in any way, except for declaring and
+ referencing additional sets of general entities and declaring
+ additional notations, label your DTD as a variant of DocBook. See
+ the maintenance documentation for more information.
+
+ Please direct all questions, bug reports, or suggestions for
+ changes to the docbook at lists.oasis-open.org mailing list. For more
+ information, see http://www.oasis-open.org/docbook/.
Copied: docbook-xml/repos/testing-any/PKGBUILD (from rev 335026, docbook-xml/trunk/PKGBUILD)
===================================================================
--- testing-any/PKGBUILD (rev 0)
+++ testing-any/PKGBUILD 2018-09-19 20:48:37 UTC (rev 335027)
@@ -0,0 +1,114 @@
+# Contributor: dorphell <dorphell at archlinux.org>
+# Contributor: Judd Vinet <jvinet at zeroflux.org>
+
+_vers=(4.{2..5})
+
+pkgname=docbook-xml
+pkgver=${_vers[-1]}
+pkgrel=8
+pkgdesc="A widely used XML scheme for writing documentation and help"
+url="https://www.oasis-open.org/docbook/"
+arch=(any)
+license=(MIT)
+depends=(libxml2)
+install=docbook-xml.install
+source=(https://docbook.org/xml/4.1.2/docbkx412.zip
+ LICENSE)
+noextract=(docbkx412.zip)
+
+for _ver in ${_vers[@]}; do
+ source+=("https://docbook.org/xml/$_ver/docbook-xml-$_ver.zip")
+ noextract+=("docbook-xml-$_ver.zip")
+done
+
+sha512sums=('f700591a671694ca0ac51f5b5b7e825df5c0b3604b20baa6afd3aaafa7ce99470ca1c261781b105b42bfa5485c23217cf3db821b3fcf2ebdae9df07bb8ae4063'
+ 'd852ab8e1442af4a91ffc32b9bb37377d98171dbc379cfd9787a2e06fc5c9b8ed04c5cd156ff5b7799973250011389456a3a3584ed4ae99362420c15235fcbb5'
+ '0c836346130d1e8f4e26e00959f6b4fd2c3c11269ba5cbf11cdc904724e189606f431c99cd5ab188877daa0eb44c58d0bc30556df3b51df480396818d61c4e0a'
+ 'f5090fb74884bae3d4fac8a3c5060bffff5d6a74272de183c181a7642e4b91f4ed32ad028537d198010782c3d98575ce679672f76a9749ed124432195886a7cb'
+ '7df5af4df24e4618b09814e4e20c147c722962531f03a40c28cd60f1db16b4c330420adf96adb7d66ed6eda84046ee91b467fd6f6fbfac2201537e2080735d76'
+ '1ee282fe86c9282610ee72c0e1d1acfc03f1afb9dc67166f438f2703109046479edb6329313ecb2949db27993077e077d111501c10b8769ebb20719eb6213d27')
+
+package() {
+ local ver xml
+
+ mkdir -p "$pkgdir/etc/xml"
+ xmlcatalog --noout --create "$pkgdir/etc/xml/docbook-xml"
+
+ mkdir docbook-xml-4.1.2
+ bsdtar -C docbook-xml-4.1.2 -xf docbkx412.zip
+ for ver in ${_vers[@]}; do
+ mkdir docbook-xml-$ver
+ bsdtar -C docbook-xml-$ver -xf docbook-xml-$ver.zip
+ done
+
+ for ver in 4.1.2 ${_vers[@]}; do
+ pushd docbook-xml-$ver
+ mkdir -p "$pkgdir/usr/share/xml/docbook/xml-dtd-$ver"
+ cp -dr docbook.cat *.dtd ent/ *.mod \
+ "$pkgdir/usr/share/xml/docbook/xml-dtd-$ver"
+ popd
+
+ xml=
+ case $ver in
+ 4.1.2) xml=' XML' ;;&
+ *)
+ xmlcatalog --noout --add "public" \
+ "-//OASIS//DTD DocBook XML V$ver//EN" \
+ "http://www.oasis-open.org/docbook/xml/$ver/docbookx.dtd" \
+ "$pkgdir/etc/xml/docbook-xml"
+ xmlcatalog --noout --add "public" \
+ "-//OASIS//DTD DocBook$xml CALS Table Model V$ver//EN" \
+ "http://www.oasis-open.org/docbook/xml/$ver/calstblx.dtd" \
+ "$pkgdir/etc/xml/docbook-xml"
+ xmlcatalog --noout --add "public" \
+ "-//OASIS//DTD XML Exchange Table Model 19990315//EN" \
+ "http://www.oasis-open.org/docbook/xml/$ver/soextblx.dtd" \
+ "$pkgdir/etc/xml/docbook-xml"
+ xmlcatalog --noout --add "public" \
+ "-//OASIS//ELEMENTS DocBook$xml Information Pool V$ver//EN" \
+ "http://www.oasis-open.org/docbook/xml/$ver/dbpoolx.mod" \
+ "$pkgdir/etc/xml/docbook-xml"
+ xmlcatalog --noout --add "public" \
+ "-//OASIS//ELEMENTS DocBook$xml Document Hierarchy V$ver//EN" \
+ "http://www.oasis-open.org/docbook/xml/$ver/dbhierx.mod" \
+ "$pkgdir/etc/xml/docbook-xml"
+ xmlcatalog --noout --add "public" \
+ "-//OASIS//ENTITIES DocBook$xml Additional General Entities V$ver//EN" \
+ "http://www.oasis-open.org/docbook/xml/$ver/dbgenent.mod" \
+ "$pkgdir/etc/xml/docbook-xml"
+ xmlcatalog --noout --add "public" \
+ "-//OASIS//ENTITIES DocBook$xml Notations V$ver//EN" \
+ "http://www.oasis-open.org/docbook/xml/$ver/dbnotnx.mod" \
+ "$pkgdir/etc/xml/docbook-xml"
+ xmlcatalog --noout --add "public" \
+ "-//OASIS//ENTITIES DocBook$xml Character Entities V$ver//EN" \
+ "http://www.oasis-open.org/docbook/xml/$ver/dbcentx.mod" \
+ "$pkgdir/etc/xml/docbook-xml"
+ ;;&
+ 4.[45])
+ xmlcatalog --noout --add "public" \
+ "-//OASIS//ELEMENTS DocBook XML HTML Tables V$ver//EN" \
+ "http://www.oasis-open.org/docbook/xml/$ver/htmltblx.mod" \
+ "$pkgdir/etc/xml/docbook-xml"
+ ;;&
+ *)
+ xmlcatalog --noout --add "rewriteSystem" \
+ "http://www.oasis-open.org/docbook/xml/$ver" \
+ "/usr/share/xml/docbook/xml-dtd-$ver" \
+ "$pkgdir/etc/xml/docbook-xml"
+ xmlcatalog --noout --add "rewriteURI" \
+ "http://www.oasis-open.org/docbook/xml/$ver" \
+ "/usr/share/xml/docbook/xml-dtd-$ver" \
+ "$pkgdir/etc/xml/docbook-xml"
+ ;;&
+ esac
+ done
+
+ install -Dt "$pkgdir/usr/share/licenses/$pkgname" -m644 LICENSE
+
+ # Fix permissions
+ find "$pkgdir" -type f -exec chmod -c a-x {} +
+ chmod -Rc u=rwX,go=rX "$pkgdir"
+}
+
+# vim:set sw=2 et:
Copied: docbook-xml/repos/testing-any/docbook-xml.install (from rev 335026, docbook-xml/trunk/docbook-xml.install)
===================================================================
--- testing-any/docbook-xml.install (rev 0)
+++ testing-any/docbook-xml.install 2018-09-19 20:48:37 UTC (rev 335027)
@@ -0,0 +1,42 @@
+post_install() {
+ if [ -e etc/xml/catalog.preserve ]; then
+ mv etc/xml/catalog.preserve etc/xml/catalog
+ elif [ ! -e etc/xml/catalog ]; then
+ xmlcatalog --noout --create etc/xml/catalog
+ fi
+ xmlcatalog --noout --add "delegatePublic" \
+ "-//OASIS//ENTITIES DocBook XML" \
+ "file:///etc/xml/docbook-xml" \
+ etc/xml/catalog
+ xmlcatalog --noout --add "delegatePublic" \
+ "-//OASIS//DTD DocBook XML" \
+ "file:///etc/xml/docbook-xml" \
+ etc/xml/catalog
+ xmlcatalog --noout --add "delegateSystem" \
+ "http://www.oasis-open.org/docbook/" \
+ "file:///etc/xml/docbook-xml" \
+ etc/xml/catalog
+ xmlcatalog --noout --add "delegateURI" \
+ "http://www.oasis-open.org/docbook/" \
+ "file:///etc/xml/docbook-xml" \
+ etc/xml/catalog
+}
+
+# arg 1: the new package version
+# arg 2: the old package version
+pre_upgrade() {
+ if [ $(vercmp $2 4.5) -lt 0 ]; then
+ xmlcatalog --del "file:///etc/xml/docbook" etc/xml/catalog > etc/xml/catalog.preserve
+ fi
+}
+
+post_upgrade() {
+ if [ $(vercmp $2 4.5) -ge 0 ]; then
+ post_remove
+ fi
+ post_install
+}
+
+post_remove() {
+ xmlcatalog --noout --del file:///etc/xml/docbook-xml etc/xml/catalog
+}
More information about the arch-commits
mailing list