Ticket #30608: Portfile-mark

File Portfile-mark, 2.9 KB (added by ryandesign (Ryan Carsten Schmidt), 13 years ago)

http://lists.macosforge.org/pipermail/macports-dev/2011-December/017144.html

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$
3
4PortSystem          1.0
5name                reduce-algebra
6svn.revision        1530
7version             3.8.0-r${svn.revision}
8categories          math
9license             modified BSD
10maintainers         gmail.com:mark.brethen
11description         REDUCE algebra system
12long_description \
13   REDUCE is an interactive program designed for general algebraic \
14   computations of interest to mathematicians, scientists and engineers.
15
16platforms           darwin
17
18homepage            http://reduce-algebra.sourceforge.net/
19
20fetch.type          svn
21svn.url \
22   https://reduce-algebra.svn.sourceforge.net/svnroot/reduce-algebra/trunk
23svn.method          checkout
24worksrcdir          trunk
25
26depends_build       port:pkgconfig
27
28depends_lib         port:xorg-libX11 \
29                    port:Xft2 \
30                    port:xorg-libXext \
31                    port:ncurses
32
33configure.args      --with-psl
34
35use_parallel_build  no
36universal_variant   no
37
38post-build {
39    if {[variant_isset html]} {
40            system "cd ${worksrcpath}/doc/manual; sh mkhtml.sh"
41    } 
42   
43    if {[variant_isset pdf]} {
44            system "cd ${worksrcpath}/doc/manual; sh mkpdf.sh"
45    }
46}
47
48variant html description {Installs documentation in HTML format} {
49        depends_build-append bin:makeindex:texlive-basic
50    depends_build-append bin:mk4ht:texlive-htmlxml
51} 
52
53variant pdf description {Installs documentation in PDF format} {
54        depends_build-append bin:makeindex:texlive-basic
55    depends_build-append bin:pdflatex:texlive-basic     
56} 
57
58destroot {
59# At present 'make install' is deeply broken, so manually install required files
60    set dest_dir  ${prefix}/libexec/${name}
61
62    xinstall -d ${destroot}${dest_dir}/doc
63
64    xinstall -m 0644 -W ${worksrcpath} BUGS BUILDING Contributor-Release.txt \
65            DEPENDENCY_TRACKING INSTALL README ${destroot}${dest_dir}/doc
66
67    if {[variant_isset html]} {
68        xinstall -d ${destroot}${dest_dir}/doc/html
69        foreach f [glob [file join ${worksrcpath}/doc/manual *.html]] {
70            eval xinstall -m 0644 ${f} ${destroot}${dest_dir}/doc/html
71        }
72    }
73
74    if {[variant_isset pdf]} {
75        xinstall -d ${destroot}${dest_dir}/doc/pdf
76        xinstall -m 0644 ${worksrcpath}/doc/manual/manual-pdf.pdf ${destroot}${dest_dir}/doc/pdf
77    }
78
79    xinstall -d ${destroot}${dest_dir}/bin
80    xinstall ${worksrcpath}/bin/redpsl ${destroot}${dest_dir}/bin
81
82    xinstall -d ${destroot}${dest_dir}/pslbuild   
83    system "cp -a ${worksrcpath}/pslbuild/* ${destroot}${dest_dir}/pslbuild"
84
85    xinstall -d ${destroot}${dest_dir}/scripts
86    system "cp -a ${worksrcpath}/scripts/* ${destroot}${dest_dir}/scripts"
87
88    xinstall ${worksrcpath}/config.guess ${destroot}${dest_dir}
89}
90
91livecheck.type      none
92
93notes "
94        To use the PSL version of Reduce, add this directory to your PATH environment variable:
95            ${prefix}/libexec/reduce-algebra/bin/
96         
97"