source: trunk/dports/textproc/dblatex/Portfile @ 134131

Last change on this file since 134131 was 134131, checked in by cal@…, 5 years ago

dblatex: fix "can't find docbook.sty", closes #47115

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.7 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 134131 2015-03-18 22:44:40Z cal@macports.org $
3
4PortSystem          1.0
5PortGroup           python 1.0
6PortGroup           texlive 1.0
7
8name                dblatex
9version             0.3.5
10revision            4
11categories          textproc tex
12maintainers         cal openmaintainer
13license             GPL-2+
14platforms           darwin
15supported_archs     noarch
16
17description         DocBook to LaTeX Converter
18long_description    Dblatex transforms a DocBook XML/SGML document to LaTeX. \
19                    Once transformed into LaTeX, standard LaTeX tools are \
20                    used to produce DVI, Postcript or PDF files. \
21                    dblatex tries to hide as much as possible the latex \
22                    compiling stuff by providing a single clean script to \
23                    produce directly DVI, PostScript and PDF output. \
24                    The actual output rendering is done not only by the \
25                    XSL stylesheets transformation, but also by a dedicated \
26                    LaTeX package. The goal is to allow a deep LaTeX \
27                    customisation without changing the XSL stylesheets. \
28                    Post-processing is done by Python, to make publication \
29                    faster, convert the images if needed, and do the whole \
30                    compilation.
31
32homepage            http://dblatex.sourceforge.net
33master_sites        sourceforge:project/dblatex/dblatex/dblatex-${version}
34
35checksums           sha256  0e0c144b1f7cf0e157be7f30caeff21475992754fa3d8e91cd4bdd31ac386440 \
36                    rmd160  4c6918c32d7f81330364d1e4d2d495953f1f48ed
37
38use_bzip2           yes
39
40depends_lib         port:texlive-latex-extra \
41                    port:texlive-latex-recommended \
42                    port:texlive-math-extra \
43                    port:dejavu-fonts \
44                    port:ImageMagick \
45                    port:docbook-xml \
46                    port:docbook-xsl
47
48patchfiles          patch-setup.py-remove-debian-installer.diff
49
50python.link_binaries no
51python.default_version 27
52
53# this gets assigned before python.bin is set to the version selected by the variant
54#destroot.cmd        ${python.bin} setup.py
55destroot.destdir    --root=${destroot} \
56                    --catalogs=${destroot}${prefix}/etc/xml/catalog
57
58post-destroot {
59    reinplace "s|${destroot}${prefix}|${prefix}|g" ${destroot}${python.prefix}/bin/dblatex
60    reinplace "s|#!/usr/bin/env python|#!${python.bin}|" ${destroot}${python.prefix}/bin/dblatex
61
62    fs-traverse f ${destroot}${python.prefix}/share {
63        if {[file isfile $f]} {
64            set f [string range $f [string length ${destroot}${python.prefix}/share/] end]
65            file mkdir [file dirname ${destroot}${prefix}/share/$f]
66            ln -s ${python.prefix}/share/$f ${destroot}${prefix}/share/$f
67        }
68    }
69    file mkdir ${destroot}${texlive_texmflocal}/tex/latex/dblatex
70    fs-traverse f ${destroot}${python.prefix}/share/dblatex/latex {
71        if {[file isfile $f]} {
72            if {[catch {exec ${prefix}/bin/kpsewhich -a [file tail $f]} result]} {
73                set f [string range $f [string length ${destroot}${python.prefix}/share/dblatex/latex/] end]
74                file mkdir [file dirname ${destroot}${texlive_texmflocal}/tex/latex/dblatex/$f]
75                ln -s ${python.prefix}/share/dblatex/latex/$f ${destroot}${texlive_texmflocal}/tex/latex/dblatex/$f
76            }
77        }
78    }
79    ln -s ${python.prefix}/bin/dblatex ${destroot}${prefix}/bin/
80}
81
82post-activate {
83    texlive.mktexlsr
84}
85
86post-deactivate {
87    texlive.mktexlsr
88}
89
90livecheck.type      regex
91livecheck.url       http://sourceforge.net/projects/${name}/files/
92livecheck.regex     /${name}-(\[0-9.\]+)/
Note: See TracBrowser for help on using the repository browser.