Ticket #21818: Portfile

File Portfile, 2.8 KB (added by sebastian@…, 15 years ago)

Portfile

Line 
1
2PortSystem 1.0
3
4name              gnuplot-devel
5conflicts         gnuplot
6set my_name       gnuplot
7version           4.3.0
8categories        math science
9maintainers       kallisys.net:pguyot openmaintainer
10description       A command-driven interactive function plotting program
11long_description  Gnuplot is a command-driven interactive function \
12                  plotting program. Plots any number of functions, \
13                  built up of C operators, C library functions, and \
14                  some things C doesn't have like **, sgn(), etc. \
15                  Also support for plotting data files, to compare \
16                  actual data to theoretical curves.
17platforms         darwin
18homepage          http://gnuplot.sourceforge.net/
19
20fetch.type        cvs
21cvs.root          :pserver:anonymous@gnuplot.cvs.sourceforge.net:/cvsroot/gnuplot
22cvs.module        gnuplot
23cvs.password     
24worksrcdir        gnuplot
25
26depends_lib   port:expat \
27        port:fontconfig \
28        port:gd2 \
29        port:jpeg \
30        port:pdflib \
31        port:libiconv \
32        port:libpng \
33        port:ncurses \
34        port:readline \
35        port:xpm \
36        port:zlib
37
38pre-patch {
39  # Prepare the cvs sources
40  system "cd ${worksrcpath} && ./prepare"
41}
42
43patchfiles    patch-share-LaTeX-Makefile.in
44
45platform darwin {
46  depends_lib-append    port:aquaterm
47  configure.cflags-append '-DDEFAULTTERM=\\"aqua\\"'
48}
49
50platform darwin 9 {
51  # http://developer.apple.com/qa/qa2007/qa1567.html
52  configure.ldflags-append -dylib_file /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib:/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib
53}
54
55configure.cppflags-append "-no-cpp-precomp"
56configure.args  --with-readline=${prefix} \
57                --with-gd=${prefix} \
58                --with-pdf=${prefix} \
59                --with-png=${prefix} \
60                --with-x \
61        --enable-datastrings --enable-histograms \
62        --infodir='\${prefix}/share/info' \
63        --mandir='\${prefix}/share/man' \
64        --disable-wxwidgets
65
66configure.ccache  no
67
68variant no_x11 {
69  depends_lib-delete    port:xpm
70  configure.args-delete --with-x
71  configure.args-append --without-x
72}
73
74variant wxwidgets {
75  depends_lib-append    port:wxWidgets
76  configure.args-delete --disable-wxwidgets
77  configure.args-append --with-wx-config=${prefix}/bin/wx-config
78}
79
80variant tutorial description "Build the tutorial (requires a tex install)" {
81  depends_lib-append    bin:tex:texlive_base
82  configure.args-delete --without-tutorial
83  configure.args-append --with-tutorial
84}
85
86destroot.destdir  prefix=${destroot}${prefix}
87
88#not for cvs build
89#post-destroot {
90# xinstall -d -m 0755 ${destroot}${prefix}/share/doc/${name}
91# xinstall -m 0644 ${distpath}/gnuplot.pdf \
92#   ${destroot}${prefix}/share/doc/${name}/
93#}