source: trunk/dports/textproc/docbook-utils/Portfile @ 98259

Last change on this file since 98259 was 98259, checked in by pixilla@…, 8 years ago

textproc/docbook-util:

  • Maintainer patches. Closes #36354
  • Added all patch files and an extra "helper program" from the original RPM used as source for this port.
  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.4 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 98259 2012-10-01 05:34:33Z pixilla@macports.org $
3
4PortSystem          1.0
5
6name                docbook-utils
7version             0.6.14
8revision            1
9categories          textproc
10platforms           darwin
11license             GPL-2+
12maintainers         fourpalms.org:lockhart openmaintainer
13homepage            http://sources.redhat.com/docbook-tools/
14description         Shell scripts for managing DocBook documents
15long_description    This package contains scripts are for easy conversion from DocBook \
16                    files to other formats (for example, HTML, RTF, and PostScript), and \
17                    for comparing SGML files. \
18                    Transcribed from the Fedora 15 RPM written originally by \
19                    Tim Waugh <twaugh@redhat.com> based on work by Eric Bischoff \
20                    and with recent maintenance by Ondrej Vasik <ovasik@redhat.com>.
21master_sites        ftp://sources.redhat.com/pub/docbook-tools/new-trials/SOURCES/
22
23checksums           rmd160  710fe047ea8a794cc6c0d944521184375a666e6b \
24                    sha256  48faab8ee8a7605c9342fb7b906e0815e3cee84a489182af38e8f7c0df2e92e9
25
26conflicts           docbook2X
27
28depends_lib         port:sgml-common \
29                    port:p5.12-sgmlspm \
30                    port:openjade \
31                    port:docbook-dsssl \
32                    port:docbook-sgml-4.2
33
34configure.args-append --mandir=${prefix}/share/man
35
36post-extract {
37    copy ${filespath}/docbook2man-spec.pl \
38        ${worksrcpath}/bin/
39}
40
41patch.pre_args      -p1
42patchfiles          docbook-utils-spaces.patch \
43                    docbook-utils-2ndspaces.patch \
44                    docbook-utils-w3mtxtconvert.patch \
45                    docbook-utils-grepnocolors.patch \
46                    docbook-utils-sgmlinclude.patch \
47                    docbook-utils-rtfmanpage.patch \
48                    docbook-utils-papersize.patch \
49                    docbook-utils-nofinalecho.patch \
50                    docbook-utils-newgrep.patch
51
52
53post-patch {
54    reinplace -E "s|^docdir=.+$|docdir='${prefix}/share/doc'|" \
55        ${worksrcpath}/configure
56    reinplace -E "s|^(htmldir = .+)(/html)(.+)$|\\1\\3\\2|" \
57        ${worksrcpath}/doc/HTML/Makefile.in
58
59    reinplace "s|/etc/sgml|${prefix}/etc/sgml|" \
60        ${worksrcpath}/bin/jw.in \
61        ${worksrcpath}/doc/man/Makefile.in \
62        ${worksrcpath}/doc/HTML/Makefile.in
63    reinplace "s|jade|openjade|" \
64        ${worksrcpath}/doc/man/Makefile.in \
65        ${worksrcpath}/doc/HTML/Makefile.in
66    reinplace "s|nsgmls|onsgmls|" \
67        ${worksrcpath}/doc/man/Makefile.in \
68        ${worksrcpath}/doc/HTML/Makefile.in
69
70    # Update content to docbook-4.x since we do not have 3.x available in MacPorts
71    reinplace "s|V3.1|V4.2|" ${worksrcpath}/doc/docbook-utils.sgml
72    reinplace "s|docinfo|chapterinfo|" \
73        ${worksrcpath}/doc/docbook-utils.sgml
74    reinplace "s|docinfo|refentryinfo|" \
75        ${worksrcpath}/doc/refentry/docbook2man-spec.pl.sgml \
76        ${worksrcpath}/doc/refentry/jw.sgml \
77        ${worksrcpath}/doc/refentry/frontend-spec.sgml \
78        ${worksrcpath}/doc/refentry/backend-spec.sgml \
79        ${worksrcpath}/doc/refentry/sgmldiff.sgml
80    reinplace "s|<Comment>|<!-- |" \
81        ${worksrcpath}/doc/refentry/docbook2man-spec.pl.sgml
82    reinplace "s|</Comment>| -->|" \
83        ${worksrcpath}/doc/refentry/docbook2man-spec.pl.sgml
84}
Note: See TracBrowser for help on using the repository browser.