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 90282 2012-02-29 14:35:42Z jmr@macports.org $ |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | PortGroup xcodeversion 1.0 |
---|
6 | |
---|
7 | name gnuplot |
---|
8 | version 4.6.0 |
---|
9 | categories math science |
---|
10 | # the license has some inconvenient requirements that we're not meeting |
---|
11 | # to be allowed to distribute binaries |
---|
12 | license Restrictive |
---|
13 | # luckily nothing has to link against this |
---|
14 | installs_libs no |
---|
15 | platforms darwin |
---|
16 | maintainers nomaintainer |
---|
17 | |
---|
18 | description A command-driven interactive function plotting program |
---|
19 | |
---|
20 | long_description Gnuplot is a command-driven interactive function \ |
---|
21 | plotting program. Plots any number of functions, \ |
---|
22 | built up of C operators, C library functions, and \ |
---|
23 | some things C doesn't have like **, sgn(), etc. \ |
---|
24 | Also support for plotting data files, to compare \ |
---|
25 | actual data to theoretical curves. |
---|
26 | |
---|
27 | homepage http://gnuplot.sourceforge.net/ |
---|
28 | master_sites sourceforge \ |
---|
29 | http://sourceforge.net/projects/gnuplot/files/gnuplot/${version}/:manual |
---|
30 | dist_subdir ${name}/${version} |
---|
31 | |
---|
32 | distfiles-append ${name}.pdf:manual |
---|
33 | extract.only ${distname}.tar.gz |
---|
34 | checksums ${distname}.tar.gz \ |
---|
35 | rmd160 2c06500f45fb81850b45713a2cd0e38f0021b065 \ |
---|
36 | sha256 6e60adb5039a3541f407c2ade670004178b376754c424c13f0be24c7960c17be \ |
---|
37 | ${name}.pdf \ |
---|
38 | rmd160 374614145a7b78e263b0cfbb695eb22d07dede9a \ |
---|
39 | sha256 57bd4d88e1321968ba06f29dfa322b4cd9e6beb4e0f42e1a4775d9c9a41af170 |
---|
40 | |
---|
41 | depends_lib port:expat \ |
---|
42 | port:fontconfig \ |
---|
43 | port:gd2 \ |
---|
44 | port:jpeg \ |
---|
45 | port:pdflib \ |
---|
46 | port:libiconv \ |
---|
47 | port:libpng \ |
---|
48 | port:ncurses \ |
---|
49 | port:readline \ |
---|
50 | port:xpm \ |
---|
51 | port:zlib |
---|
52 | |
---|
53 | #patchfiles patch-src-variable_c.diff |
---|
54 | |
---|
55 | platform darwin { |
---|
56 | depends_lib-append port:aquaterm |
---|
57 | configure.cflags-append -DDEFAULTTERM='"aqua"' |
---|
58 | } |
---|
59 | |
---|
60 | minimum_xcodeversions {9 3.1} |
---|
61 | |
---|
62 | configure.args --with-readline=${prefix} \ |
---|
63 | --with-gd=${prefix} \ |
---|
64 | --with-pdf=${prefix} \ |
---|
65 | --with-png=${prefix} \ |
---|
66 | --with-x \ |
---|
67 | --enable-datastrings \ |
---|
68 | --enable-histograms \ |
---|
69 | --infodir='\${prefix}/share/info' \ |
---|
70 | --mandir='\${prefix}/share/man' \ |
---|
71 | --disable-wxwidgets \ |
---|
72 | --without-latex \ |
---|
73 | --without-tutorial \ |
---|
74 | --without-cairo \ |
---|
75 | --without-lua |
---|
76 | |
---|
77 | configure.ccache no |
---|
78 | |
---|
79 | variant no_x11 { |
---|
80 | depends_lib-delete port:xpm |
---|
81 | configure.args-delete --with-x |
---|
82 | configure.args-append --without-x |
---|
83 | } |
---|
84 | |
---|
85 | # TODO: one needs an option to choose between normal and devel version, |
---|
86 | # but only devel version allows building 64-bit binaries |
---|
87 | variant wxwidgets description "Enable wxWidgets front-end" { |
---|
88 | depends_lib-append port:wxWidgets-devel |
---|
89 | configure.args-delete --disable-wxwidgets |
---|
90 | configure.args-append --with-wx-config=${prefix}/bin/wx-config |
---|
91 | } |
---|
92 | |
---|
93 | #variant wxwidgets description "Enable wxWidgets front-end" { |
---|
94 | # depends_lib-append port:wxWidgets |
---|
95 | # configure.args-delete --disable-wxwidgets |
---|
96 | # configure.args-append --with-wx-config=${prefix}/bin/wx-config |
---|
97 | #} |
---|
98 | #if {[variant_isset wxwidgets]} { |
---|
99 | # # wxWidgets is not universal and is 32-bit only |
---|
100 | # universal_variant no |
---|
101 | # supported_archs i386 ppc |
---|
102 | #} |
---|
103 | |
---|
104 | variant luaterm description "Enable Lua terminal" { |
---|
105 | depends_lib-append port:lua |
---|
106 | configure.args-delete --without-lua |
---|
107 | configure.args-append --with-lua |
---|
108 | } |
---|
109 | |
---|
110 | variant pangocairo description "Enable cairo-based terminals" { |
---|
111 | depends_lib-append path:lib/pkgconfig/pango.pc:pango |
---|
112 | configure.args-delete --without-cairo |
---|
113 | } |
---|
114 | |
---|
115 | variant tutorial description "Build the tutorial (requires a tex install)" { |
---|
116 | depends_lib-append port:texlive-latex-extra |
---|
117 | configure.args-delete --without-tutorial --without-latex |
---|
118 | configure.args-append --with-tutorial |
---|
119 | } |
---|
120 | |
---|
121 | default_variants +luaterm +pangocairo |
---|
122 | |
---|
123 | destroot.destdir prefix=${destroot}${prefix} |
---|
124 | |
---|
125 | post-destroot { |
---|
126 | xinstall -d -m 0755 ${destroot}${prefix}/share/doc/${name} |
---|
127 | xinstall -m 0644 ${distpath}/${name}.pdf \ |
---|
128 | ${destroot}${prefix}/share/doc/${name}/ |
---|
129 | } |
---|