# -*- coding: utf-8; mode: tcl; tab-width: 4; c-basic-offset: 4 -*- # $Id: Portfile 87608 2011-11-28 14:47:44Z mmoll@macports.org $ PortSystem 1.0 PortGroup python 1.0 set realname graph-tool name py-${realname} version 2.2.15 categories python science platforms darwin license GPL-3 maintainers skewed.de:tiago mmoll description Efficient python graph module long_description graph-tool is an efficient python module for manipulation \ and statistical analysis of graphs. The internal data \ structures and most algorithms are implemented in C++ with \ the Boost Graph Library. homepage http://graph-tool.skewed.de master_sites http://downloads.skewed.de/graph-tool/ use_bzip2 yes checksums md5 24dd4aa307fc64c5988a4d827ee16bbd \ sha1 6498ce3208b8d7b1325dcac38dafb24bb8b9ddfe \ rmd160 c998c1110653a487d2ec1ae5aa27c61004f8e011 distname ${realname}-${version} patchfiles patch-dl_import.py.diff python.versions 25 26 27 31 32 python.default_version 27 # graph-tool relies on Boost.Python, so make sure it is installed. pre-fetch { if {![file exists ${prefix}/lib/libboost_python-mt.dylib]} { return -code error "Please reinstall boost with one of the python variants enabled." } } if {$subport != $name} { universal_variant no depends_lib-append port:boost \ port:cgal \ port:expat \ path:bin/dot:graphviz \ port:py${python.version}-numpy \ port:py${python.version}-scipy use_configure yes configure.env-append PYTHON=${python.bin} \ PYTHON_VERSION=${python.branch} \ PYTHON_CPPFLAGS=-I${python.include} \ PYTHON_LDFLAGS="-L${python.libdir} -lpython${python.branch}" configure.cflags-append -I${prefix}/include configure.cxxflags-append -I${prefix}/include configure.ldflags-append -L${prefix}/lib configure.args-append --with-boost=${prefix} build.cmd make build.target all destroot.cmd make destroot.destdir DESTDIR=${destroot} if {${configure.compiler} == "clang"} { configure.compiler llvm-gcc-4.2 } if {${configure.compiler} == "llvm-gcc-4.2" || ${configure.compiler} == "gcc-4.0" || ${configure.compiler} == "gcc-4.2" || ${configure.compiler} == "apple-gcc-4.0" || ${configure.compiler} == "apple-gcc-4.2" || ${configure.compiler} == "macports-gcc-4.1" || ${configure.compiler} == "macports-gcc-4.2" || ${configure.compiler} == "macports-gcc-4.3"} { configure.cxxflags-append -DCGAL_CFG_NO_CPP0X_VARIADIC_TEMPLATES } # not supported by clang at the moment variant openmp description {Add support for openmp} { configure.args-append --enable-openmp } post-destroot { xinstall -d ${destroot}${python.pkgd} file rename ${destroot}${prefix}/lib/python${python.branch}/site-packages/graph_tool \ ${destroot}${python.pkgd} file rename ${destroot}${prefix}/doc/graph-tool \ ${destroot}${prefix}/share/doc/graph-tool } } if {$name == $subport} { livecheck.type regex livecheck.url $homepage livecheck.regex Version (\[0-9.\]+) of graph-tool } else { livecheck.type none }