source: trunk/dports/textproc/docbook-xml-412/Portfile @ 20558

Last change on this file since 20558 was 20558, checked in by blair@…, 14 years ago

Set svn:eol-style to 'native' and svn:keywords to 'Id'.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.6 KB
Line 
1# $Id: Portfile 20558 2006-11-06 23:28:39Z blair@macports.org $
2
3PortSystem 1.0
4
5name            docbook-xml-412
6version         4.1.2
7description     the docbook xml dtds
8categories      textproc
9platforms       darwin
10maintainers     rhwood@macports.org
11depends_build   bin:unzip:unzip
12distname        docbkx412
13
14master_sites    http://www.oasis-open.org/docbook/xml/4.1.2/
15checksums       md5 900d7609fb7e6d78901b357e4acfbc17
16
17use_zip         yes
18extract.suffix  .zip
19extract.cmd     unzip
20
21depends_build   bin:xmlcatalog:libxml2
22
23configure       {}
24build           {}
25
26destroot                {
27        file mkdir ${destroot}/${prefix}/share/xml/docbook/${version}
28        file mkdir ${destroot}/${prefix}/share/xml/docbook/${version}/ent
29        system "for file in \
30                `unzip -l ${distpath}/${distname} | awk '/:\[0-9\].*\[^\\/\]\$/\{print \$4\}'`; do \
31                install -cv ${workpath}/\$file ${destroot}/${prefix}/share/xml/docbook/${version}/\$file; \
32                done"
33}
34
35post-activate {
36        file mkdir ${prefix}/etc/xml
37        if {![file exists ${prefix}/etc/xml/docbook]} {
38                system "xmlcatalog --noout --create ${prefix}/etc/xml/docbook"
39        }
40        system "\
41                xmlcatalog --noout --add 'public' \
42                        '-//OASIS//ELEMENTS DocBook XML Information Pool V${version}//EN' \
43                        'file://${prefix}/share/xml/docbook/${version}/dbpoolx.mod' ${prefix}/etc/xml/docbook
44                xmlcatalog --noout --add 'public' \
45                        '-//OASIS//DTD DocBook XML V${version}//EN' \
46                        'file://${prefix}/share/xml/docbook/${version}/docbookx.dtd' ${prefix}/etc/xml/docbook
47                xmlcatalog --noout --add 'public' \
48                        '-//OASIS//ENTITIES DocBook XML Character Entities V${version}//EN' \
49                        'file://${prefix}/share/xml/docbook/${version}/dbcentx.mod' ${prefix}/etc/xml/docbook
50                xmlcatalog --noout --add 'public' \
51                        '-//OASIS//ENTITIES DocBook XML Notations V${version}//EN' \
52                        'file://${prefix}/share/xml/docbook/${version}/dbnotnx.mod' ${prefix}/etc/xml/docbook
53                xmlcatalog --noout --add 'public' \
54                        '-//OASIS//ENTITIES DocBook XML Additional General Entities V${version}//EN' \
55                        'file://${prefix}/share/xml/docbook/${version}/dbgenent.mod' ${prefix}/etc/xml/docbook
56                xmlcatalog --noout --add 'public' \
57                        '-//OASIS//ELEMENTS DocBook XML Document Hierarchy V${version}//EN' \
58                        'file://${prefix}/share/xml/docbook/${version}/dbhierx.mod' ${prefix}/etc/xml/docbook
59                xmlcatalog --noout --add 'public' \
60                        '-//OASIS//DTD XML Exchange Table Model 19990315//EN' \
61                        'file://${prefix}/share/xml/docbook/${version}/soextblx.dtd' ${prefix}/etc/xml/docbook
62                xmlcatalog --noout --add 'public' \
63                        '-//OASIS//DTD DocBook XML CALS Table Model V${version}//EN' \
64                        'file://${prefix}/share/xml/docbook/${version}/calstblx.dtd' ${prefix}/etc/xml/docbook
65                xmlcatalog --noout --add 'rewriteSystem' \
66                        'http://www.oasis-open.org/docbook/xml/${version}' \
67                        'file://${prefix}/share/xml/docbook/${version}' ${prefix}/etc/xml/docbook
68                xmlcatalog --noout --add 'rewriteURI' \
69                        'http://www.oasis-open.org/docbook/xml/${version}' \
70                        'file://${prefix}/share/xml/docbook/${version}' ${prefix}/etc/xml/docbook
71        "
72        # add catalog above to root XML catalog
73        if {![file exists ${prefix}/etc/xml/catalog]} {
74                system "xmlcatalog --noout --create ${prefix}/etc/xml/catalog"
75        }
76        system "\
77                xmlcatalog --noout --add 'delegatePublic' \
78                    '-//OASIS//ENTITIES DocBook XML' \
79                    'file://${prefix}/etc/xml/docbook' ${prefix}/etc/xml/catalog
80                xmlcatalog --noout --add 'delegatePublic' \
81                    '-//OASIS//DTD DocBook XML' \
82                    'file://${prefix}/etc/xml/docbook' ${prefix}/etc/xml/catalog
83                xmlcatalog --noout --add 'delegateSystem' \
84                    'http://www.oasis-open.org/docbook/' \
85                    'file://${prefix}/etc/xml/docbook' ${prefix}/etc/xml/catalog
86                xmlcatalog --noout --add 'delegateURI' \
87                    'http://www.oasis-open.org/docbook/' \
88                    'file://${prefix}/etc/xml/docbook' ${prefix}/etc/xml/catalog
89        "
90}
Note: See TracBrowser for help on using the repository browser.