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 147088 2016-03-26 09:44:32Z takeshi@macports.org $ |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | |
---|
6 | name grace |
---|
7 | version 5.1.25 |
---|
8 | revision 1 |
---|
9 | categories x11 math science print |
---|
10 | license GPL-2+ |
---|
11 | platforms darwin |
---|
12 | maintainers nomaintainer |
---|
13 | description WYSIWYG tool to make two-dimensional plots of numerical data |
---|
14 | long_description ${description} |
---|
15 | |
---|
16 | homepage http://plasma-gate.weizmann.ac.il/Grace/ |
---|
17 | set sub grace/src/stable/ |
---|
18 | master_sites ftp://ftp.fu-berlin.de/unix/graphics/${sub} \ |
---|
19 | ftp://ftp.u-aizu.ac.jp/pub/SciEng/math/${sub} |
---|
20 | |
---|
21 | checksums rmd160 3fff22b3ceaaffddd81c8d23d26623f2e8f87c7c \ |
---|
22 | sha256 751ab9917ed0f6232073c193aba74046037e185d73b77bab0f5af3e3ff1da2ac |
---|
23 | |
---|
24 | depends_lib lib:libXm:openmotif \ |
---|
25 | port:jpeg \ |
---|
26 | port:libpng \ |
---|
27 | port:pdflib \ |
---|
28 | port:xorg-libXmu \ |
---|
29 | port:xorg-libXp \ |
---|
30 | port:xpm \ |
---|
31 | port:zlib |
---|
32 | |
---|
33 | depends_run port:openbrowser |
---|
34 | |
---|
35 | patchfiles patch-configure.diff |
---|
36 | |
---|
37 | # The default optimization level apparently causes xmgrace to crash for some users. |
---|
38 | configure.optflags -O1 |
---|
39 | configure.pre_args --prefix=${prefix}/lib |
---|
40 | configure.args --with-helpviewer="${prefix}/bin/openbrowser ${prefix}/share/doc/${name}/`basename %s`" \ |
---|
41 | --x-include=${prefix}/include --x-lib=${prefix}/lib --with-bundled-t1lib=yes |
---|
42 | |
---|
43 | post-destroot { |
---|
44 | xinstall -m 755 -d ${destroot}${prefix}/share/doc |
---|
45 | file delete ${destroot}${prefix}/bin |
---|
46 | file rename ${destroot}${prefix}/lib/grace/bin ${destroot}${prefix}/bin |
---|
47 | file rename ${destroot}${prefix}/lib/grace/doc ${destroot}${prefix}/share/doc/${name} |
---|
48 | file rename ${destroot}${prefix}/lib/grace/examples ${destroot}${prefix}/share/doc/${name}/examples |
---|
49 | file rename ${destroot}${prefix}/lib/grace/include/grace_np.h ${destroot}${prefix}/include/grace_np.h |
---|
50 | file rename ${destroot}${prefix}/lib/grace/lib/libgrace_np.a ${destroot}${prefix}/lib/libgrace_np.a |
---|
51 | system "cd ${destroot}${prefix}/share/doc/${name} && ln -s . doc" |
---|
52 | system "cd ${destroot}${prefix}/share && mv doc/grace/*.1 man/man1/" |
---|
53 | } |
---|
54 | |
---|
55 | variant netcdf description {Support for NetCDF data files} { |
---|
56 | depends_lib-append port:netcdf |
---|
57 | configure.args-append --enable-netcdf |
---|
58 | } |
---|
59 | |
---|
60 | livecheck.type regex |
---|
61 | livecheck.url [lindex ${master_sites} 0] |
---|
62 | livecheck.regex ${name}-(\[0-9.\]+)${extract.suffix} |
---|