# $Id$ PortSystem 1.0 PortGroup cmake 1.0 name flann version 1.7.1 revision 4 categories science devel maintainers mmoll description Fast Library for Approximate Nearest Neighbors long_description FLANN is a library for performing fast approximate \ nearest neighbor searches in high dimensional spaces. \ It contains a collection of algorithms we found to \ work best for nearest neighbor search and a system \ for automatically choosing the best algorithm and \ optimum parameters depending on the dataset. homepage http://people.cs.ubc.ca/~mariusm/index.php/FLANN/FLANN platforms darwin license BSD master_sites http://people.cs.ubc.ca/~mariusm/uploads/FLANN/ distname ${name}-${version}-src dist_subdir ${name}/${version}_1 use_zip yes extract.mkdir yes checksums md5 d780795f523eabda7c7ea09c6f5cf235 \ sha1 61b9858620528919ea60a2a4b085ccc2b3c2d138 \ rmd160 cec1ce99d2c91ddf8f20d5aa8009a08c5347b904 depends_lib port:hdf5-18 port:tbb patchfiles patch-src-cpp-CMakeLists.txt.diff patch-src-python-CMakeLists.txt.diff patch.dir ${worksrcpath}/${worksrcdir} # MPI support is automatically disabled if hdf5-18 is installed without the +openmpi variant configure.args-append ${distname} -DBUILD_MATLAB_BINDINGS=OFF -DUSE_MPI=ON -DBUILD_CUDA_LIB=OFF \ -DMPIEXEC=${prefix}/lib/openmpi/bin/mpiexec \ -DMPI_COMPILER=${prefix}/lib/openmpi/bin/mpic++ variant python26 description {Use python2.6 for python bindings} conflicts python27 python31 python32 { depends_lib-append port:python26 configure.args-append -DPYTHON_EXECUTABLE=${prefix}/bin/python2.6 post-patch { reinplace "s|@@PREFIX@@|${destroot}${prefix}|g" ${patch.dir}/src/python/CMakeLists.txt reinplace "s|@@PYTHON_LIB@@|${destroot}${prefix}/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6|g" ${patch.dir}/src/python/CMakeLists.txt } } variant python27 description {Use python2.7 for python bindings} conflicts python26 python31 python32 { depends_lib-append port:python27 configure.args-append -DPYTHON_EXECUTABLE=${prefix}/bin/python2.7 post-patch { reinplace "s|@@PREFIX@@|${destroot}${prefix}|g" ${patch.dir}/src/python/CMakeLists.txt reinplace "s|@@PYTHON_LIB@@|${destroot}${prefix}/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7|g" ${patch.dir}/src/python/CMakeLists.txt } } variant python31 description {Use python3.1 for python bindings} conflicts python26 python27 python32 { depends_lib-append port:python31 configure.args-append -DPYTHON_EXECUTABLE=${prefix}/bin/python3.1 post-patch { reinplace "s|@@PREFIX@@|${destroot}${prefix}|g" ${patch.dir}/src/python/CMakeLists.txt reinplace "s|@@PYTHON_LIB@@|${destroot}${prefix}/Library/Frameworks/Python.framework/Versions/3.1/lib/python3.1|g" ${patch.dir}/src/python/CMakeLists.txt } } variant python32 description {Use python3.2 for python bindings} conflicts python26 python27 python31 { depends_lib-append port:python32 configure.args-append -DPYTHON_EXECUTABLE=${prefix}/bin/python3.2 post-patch { reinplace "s|@@PREFIX@@|${destroot}${prefix}|g" ${patch.dir}/src/python/CMakeLists.txt reinplace "s|@@PYTHON_LIB@@|${destroot}${prefix}/Library/Frameworks/Python.framework/Versions/3.2/lib/python3.2|g" ${patch.dir}/src/python/CMakeLists.txt } } variant cuda description {Enable CUDA support} { configure.args-delete -DBUILD_CUDA_LIB=OFF configure.args-append -DBUILD_CUDA_LIB=ON } # CUDA is enabled by default (compilation won't fail if CUDA is not installed), # but people with broken CUDA installs can disable the CUDA bindings. default_variants +cuda livecheck.type regex livecheck.url ${homepage} livecheck.regex Version (\[0-9.\]+)