1 | # $Id: Portfile 22893 2007-03-18 04:11:24Z takanori@macports.org $ |
---|
2 | PortSystem 1.0 |
---|
3 | name plplot |
---|
4 | version 5.7.3 |
---|
5 | revision 1 |
---|
6 | platforms darwin |
---|
7 | maintainers takeshi@mac.com |
---|
8 | categories science |
---|
9 | description Scientific plotting package |
---|
10 | master_sites sourceforge |
---|
11 | checksums md5 8c5ed411bc63a4fd07b362a1b9a3e46c |
---|
12 | homepage http://plplot.sourceforge.net/ |
---|
13 | long_description { \ |
---|
14 | PLplot is relatively small, portable, freely distributable, \ |
---|
15 | and is rich enough to satisfy most users. \ |
---|
16 | It has a wide range of plot types including line (linear, log), \ |
---|
17 | contour, 3D, fill, and almost 1000 characters \ |
---|
18 | (including Greek and mathematical) in its extended font set. \ |
---|
19 | The package is designed to make it easy to quickly get graphical output; \ |
---|
20 | only a handful of function calls is typically required. \ |
---|
21 | For more advanced use, virtually all aspects of plotting are configurable.} |
---|
22 | |
---|
23 | depends_lib port:cmake \ |
---|
24 | port:expat \ |
---|
25 | port:fontconfig \ |
---|
26 | port:freefont-ttf \ |
---|
27 | port:freetype \ |
---|
28 | port:g95 \ |
---|
29 | port:gd2 \ |
---|
30 | port:libiconv \ |
---|
31 | port:jpeg \ |
---|
32 | port:libpng \ |
---|
33 | port:odcctools \ |
---|
34 | port:pkgconfig \ |
---|
35 | port:tcl \ |
---|
36 | port:tk \ |
---|
37 | port:zlib |
---|
38 | |
---|
39 | # port:fftw-3 |
---|
40 | # port:hdf5 |
---|
41 | # port:readline |
---|
42 | # port:swig |
---|
43 | |
---|
44 | patchfiles patch-x18f |
---|
45 | |
---|
46 | pre-configure { |
---|
47 | file mkdir ${workpath}/build |
---|
48 | } |
---|
49 | |
---|
50 | configure.dir ${workpath}/build |
---|
51 | configure.cmd cmake |
---|
52 | configure.env HOME=${workpath} |
---|
53 | configure.pre_args -DCMAKE_INSTALL_PREFIX=${prefix} |
---|
54 | configure.args -DCMAKE_VERBOSE_MAKEFILE=ON \ |
---|
55 | -DCMAKE_Fortran_FLAGS=-O2 \ |
---|
56 | -DCMAKE_C_COMPILER=/usr/bin/cc \ |
---|
57 | -DCMAKE_C_FLAGS=\"-O2 -I${prefix}/include\" \ |
---|
58 | -DCMAKE_CXX_COMPILER=/usr/bin/c++ \ |
---|
59 | -DCMAKE_CXX_FLAGS=\"-O2 -I${prefix}/include\" \ |
---|
60 | -DCMAKE_INCLUDE_PATH=${prefix}/include \ |
---|
61 | -DCMAKE_LIBRARY_PATH=${prefix}/lib \ |
---|
62 | -DTCL_INCLUDE_PATH=${prefix}/include \ |
---|
63 | -DTCL_LIBRARY=${prefix}/lib/libtcl.dylib \ |
---|
64 | -DTCL_STUB_LIBRARY=${prefix}/lib/libtclstub8.4.a \ |
---|
65 | -DTK_INCLUDE_PATH=${prefix}/include \ |
---|
66 | -DTK_LIBRARY=${prefix}/lib/libtk.dylib \ |
---|
67 | -DTK_STUB_LIBRARY=${prefix}/lib/libtkstub8.4.a \ |
---|
68 | -DFREETYPE_INCLUDE_DIR=${prefix}/include/freetype2 \ |
---|
69 | -DFREETYPE_LIBRARY=${prefix}/lib/libfreetype.dylib \ |
---|
70 | -DPL_FREETYPE_FONT_PATH=${prefix}/share/fonts/freefont-ttf \ |
---|
71 | -DWITH_FREETYPE=ON \ |
---|
72 | -DPLD_aqt=OFF \ |
---|
73 | -DPLD_tkwin=ON \ |
---|
74 | -DPLD_wxwidgets=OFF \ |
---|
75 | -DPLD_gnome=OFF \ |
---|
76 | -DPLD_gcw=OFF \ |
---|
77 | -DENABLE_java=OFF \ |
---|
78 | -DENABLE_python=OFF \ |
---|
79 | -DENABLE_octave=OFF \ |
---|
80 | -DENABLE_pdl=OFF \ |
---|
81 | -DENABLE_itkl=OFF \ |
---|
82 | -DENABLE_itk=OFF \ |
---|
83 | -DBUILD_TEST=ON |
---|
84 | # -DSWIG_DIR=${prefix}/bin |
---|
85 | configure.post_args ../${distname} |
---|
86 | |
---|
87 | build.dir ${workpath}/build |
---|
88 | |
---|
89 | platform i386 { |
---|
90 | configure.args-append -DCMAKE_MODULE_LINKER_FLAGS=\"-undefined dynamic_lookup\" \ |
---|
91 | -DCMAKE_EXE_LINKER_FLAGS=\"-undefined dynamic_lookup\" |
---|
92 | } |
---|
93 | |
---|
94 | # To use Gnome Canvas Widget |
---|
95 | variant gcw { |
---|
96 | depends_lib-append port:atk \ |
---|
97 | port:cairo \ |
---|
98 | port:gettext \ |
---|
99 | port:glib2 \ |
---|
100 | port:gtk2 \ |
---|
101 | port:libart_lgpl \ |
---|
102 | port:libgnomecanvas \ |
---|
103 | port:libgnomeprint \ |
---|
104 | port:libgnomeprintui \ |
---|
105 | port:libxml2 \ |
---|
106 | port:pango \ |
---|
107 | port:tiff \ |
---|
108 | port:xrender |
---|
109 | configure.args-delete -DPLD_gcw=OFF |
---|
110 | configure.args-append -DPLD_gcw=ON |
---|
111 | } |
---|
112 | |
---|
113 | if {![variant_isset g95]} { |
---|
114 | default_variants +gcc42 |
---|
115 | } |
---|
116 | variant gcc42 conflicts g95 description {Build using gcc42 (default)} { |
---|
117 | depends_build-append port:gcc42 |
---|
118 | configure.args-append -DCMAKE_Fortran_COMPILER=\"${prefix}/bin/gfortran\" |
---|
119 | } |
---|
120 | variant g95 conflicts gcc42 description {Build using g95} { |
---|
121 | depends_build-append port:g95 |
---|
122 | configure.args-append -DCMAKE_Fortran_COMPILER=\"${prefix}/bin/g95\" |
---|
123 | } |
---|
124 | |
---|
125 | variant octave { |
---|
126 | depends_lib-append port:octave |
---|
127 | configure.args-delete -DPLD_gcw=OFF |
---|
128 | configure.args-delete -DENABLE_octave=OFF |
---|
129 | configure.args-append -DENABLE_octave=ON |
---|
130 | } |
---|