# $Id: Portfile 27348 2007-07-30 14:50:04Z takanori@macports.org $ PortSystem 1.0 name plplot version 5.7.3 revision 2 platforms darwin maintainers takeshi@mac.com categories science description Scientific plotting package master_sites sourceforge checksums md5 8c5ed411bc63a4fd07b362a1b9a3e46c homepage http://plplot.sourceforge.net/ long_description { \ PLplot is relatively small, portable, freely distributable, \ and is rich enough to satisfy most users. \ It has a wide range of plot types including line (linear, log), \ contour, 3D, fill, and almost 1000 characters \ (including Greek and mathematical) in its extended font set. \ The package is designed to make it easy to quickly get graphical output; \ only a handful of function calls is typically required. \ For more advanced use, virtually all aspects of plotting are configurable.} depends_lib port:cmake \ port:expat \ port:fontconfig \ port:freefont-ttf \ port:freetype \ port:gd2 \ port:libiconv \ port:jpeg \ port:libpng \ port:odcctools \ port:pkgconfig \ port:tcl \ port:tk \ port:zlib # port:fftw-3 # port:hdf5 # port:readline # port:swig patchfiles patch-x18f pre-configure { file mkdir ${workpath}/build } configure.dir ${workpath}/build configure.cmd cmake configure.env HOME=${workpath} configure.pre_args -DCMAKE_INSTALL_PREFIX=${prefix} configure.args -DCMAKE_VERBOSE_MAKEFILE=ON \ -DCMAKE_Fortran_FLAGS=-O2 \ -DCMAKE_C_COMPILER=/usr/bin/cc \ -DCMAKE_C_FLAGS=\"-O2 -I${prefix}/include\" \ -DCMAKE_CXX_COMPILER=/usr/bin/c++ \ -DCMAKE_CXX_FLAGS=\"-O2 -I${prefix}/include\" \ -DCMAKE_INCLUDE_PATH=${prefix}/include \ -DCMAKE_LIBRARY_PATH=${prefix}/lib \ -DTCL_INCLUDE_PATH=${prefix}/include \ -DTCL_LIBRARY=${prefix}/lib/libtcl.dylib \ -DTCL_STUB_LIBRARY=${prefix}/lib/libtclstub8.4.a \ -DTK_INCLUDE_PATH=${prefix}/include \ -DTK_LIBRARY=${prefix}/lib/libtk.dylib \ -DTK_STUB_LIBRARY=${prefix}/lib/libtkstub8.4.a \ -DFREETYPE_INCLUDE_DIR=${prefix}/include/freetype2 \ -DFREETYPE_LIBRARY=${prefix}/lib/libfreetype.dylib \ -DPL_FREETYPE_FONT_PATH=${prefix}/share/fonts/freefont-ttf \ -DWITH_FREETYPE=ON \ -DPLD_aqt=OFF \ -DPLD_tkwin=ON \ -DPLD_wxwidgets=OFF \ -DPLD_gnome=OFF \ -DPLD_gcw=OFF \ -DENABLE_java=OFF \ -DENABLE_python=OFF \ -DENABLE_octave=OFF \ -DENABLE_pdl=OFF \ -DENABLE_itkl=OFF \ -DENABLE_itk=OFF \ -DBUILD_TEST=ON # -DSWIG_DIR=${prefix}/bin configure.post_args ../${distname} pre-configure { if {[file exists ${prefix}/lib/libplplotd.dylib]} { return -code error "Before upgrading plplot, please uninstall (or deactivate) the old version of plplot." } } build.dir ${workpath}/build platform i386 { configure.args-append -DCMAKE_MODULE_LINKER_FLAGS=\"-undefined dynamic_lookup\" \ -DCMAKE_EXE_LINKER_FLAGS=\"-undefined dynamic_lookup\" } variant gcw description {Add support for Gnome Canvas Widget} { depends_lib-append port:atk \ port:cairo \ port:gettext \ port:glib2 \ port:gtk2 \ port:libart_lgpl \ port:libgnomecanvas \ port:libgnomeprint \ port:libgnomeprintui \ port:libxml2 \ port:pango \ port:tiff \ port:xrender configure.args-delete -DPLD_gcw=OFF configure.args-append -DPLD_gcw=ON } if {![variant_isset g95]} { default_variants +gcc42 } variant gcc42 conflicts g95 description {Build using gcc42 (default)} { depends_lib-append port:gcc42 configure.args-append -DCMAKE_Fortran_COMPILER=\"${prefix}/bin/gfortran-mp-4.2\" } variant g95 conflicts gcc42 description {Build using g95} { depends_lib-append port:g95 configure.args-append -DCMAKE_Fortran_COMPILER=\"${prefix}/bin/g95\" } variant octave description {Add support for Octave} { depends_lib-append port:octave configure.args-delete -DENABLE_octave=OFF configure.args-append -DENABLE_octave=ON }