archrelease: copy trunk to extra-x86_64
[arch-packages.git] / docbook5-xml / repos / extra-any / docbook5-xml.install
blobff76394f0ce9c18beb9048f3f4e8bf09bbfc6365
1 _datadir=/usr/share
2 _rootcatalog=/etc/xml/catalog
4 post_install() {
5   if [[ -w $_rootcatalog ]]; then
6     for v in 5.{0,1}; do
7       xmlcatalog --noout --add "delegatePublic" \
8         "-//OASIS//DTD DocBook XML ${v}//EN" \
9         "file://${_datadir}/xml/docbook/schema/dtd/${v}/catalog.xml" \
10         ${_rootcatalog}
11       xmlcatalog --noout --add "delegateSystem" \
12         "http://docbook.org/xml/${v}/dtd/" \
13         "file://${_datadir}/xml/docbook/schema/dtd/${v}/catalog.xml" \
14         ${_rootcatalog}
15       xmlcatalog --noout --add "delegateURI" \
16         "http://docbook.org/xml/${v}/dtd/" \
17         "file://${_datadir}/xml/docbook/schema/dtd/${v}/catalog.xml" \
18         ${_rootcatalog}
19       xmlcatalog --noout --add "delegateURI" \
20         "http://docbook.org/xml/${v}/rng/"  \
21         "file://${_datadir}/xml/docbook/schema/rng/${v}/catalog.xml" \
22         ${_rootcatalog}
23       xmlcatalog --noout --add "delegateURI" \
24         "http://docbook.org/xml/${v}/sch/"  \
25         "file://${_datadir}/xml/docbook/schema/sch/${v}/catalog.xml" \
26         ${_rootcatalog}
27       xmlcatalog --noout --add "delegateURI" \
28         "http://docbook.org/xml/${v}/xsd/"  \
29         "file://${_datadir}/xml/docbook/schema/xsd/${v}/catalog.xml" \
30         ${_rootcatalog}
31     done
32   fi
35 post_remove() {
36   if [[ -w $_rootcatalog ]]; then
37     for v in 5.{0,1}; do
38        xmlcatalog --noout --del \
39        "file://${_datadir}/xml/docbook/schema/dtd/${v}/catalog.xml" \
40        ${_rootcatalog}
41        xmlcatalog --noout --del \
42        "file://${_datadir}/xml/docbook/schema/rng/${v}/catalog.xml" \
43        ${_rootcatalog}
44        xmlcatalog --noout --del \
45        "file://${_datadir}/xml/docbook/schema/sch/${v}/catalog.xml" \
46        ${_rootcatalog}
47        xmlcatalog --noout --del \
48        "file://${_datadir}/xml/docbook/schema/xsd/${v}/catalog.xml" \
49        ${_rootcatalog}
50      done
51   fi