[74564] trunk/dports/science/flann

mmoll at macports.org mmoll at macports.org
Tue Dec 21 13:46:02 PST 2010


Revision: 74564
          http://trac.macports.org/changeset/74564
Author:   mmoll at macports.org
Date:     2010-12-21 13:45:54 -0800 (Tue, 21 Dec 2010)
Log Message:
-----------
science/flann: update to 1.6.6

Modified Paths:
--------------
    trunk/dports/science/flann/Portfile

Added Paths:
-----------
    trunk/dports/science/flann/files/patch-flann-1.6.6.diff

Removed Paths:
-------------
    trunk/dports/science/flann/files/patch-CMakeLists.txt.diff
    trunk/dports/science/flann/files/patch-cpp-CMakeLists.txt.diff

Modified: trunk/dports/science/flann/Portfile
===================================================================
--- trunk/dports/science/flann/Portfile	2010-12-21 21:29:15 UTC (rev 74563)
+++ trunk/dports/science/flann/Portfile	2010-12-21 21:45:54 UTC (rev 74564)
@@ -3,30 +3,50 @@
 PortSystem 1.0
 PortGroup cmake 1.0
 name                flann
-version             1.2
+version             1.6.6
 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.
+                    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
+license             BSD
 master_sites        http://people.cs.ubc.ca/~mariusm/uploads/FLANN/
-distname	    ${name}-${version}-src
-use_zip		    yes
-worksrcdir	    ${distname}/src
-#configure.args-append src/CMakeLists.txt
-checksums           md5     03ffd00523fd629e259febcc762d4668 \
-                    sha1    6d82bbdb28b2d04a9808f071c1efeac3b1224380 \
-                    rmd160  fc05574746727b220f1da83924680e033ff48264
+distname            ${name}-${version}-src
+use_zip             yes
+extract.mkdir       yes
+checksums           md5     9f162b8090610e0a91a3262a04bac0cf \
+                    sha1    d14a359f9d07e6b1ea84968d6d658afd2a13f89a \
+                    rmd160  28c9d11f7d9eaaf0cce86dbceb03cf0b6cb2a7ca
+patchfiles          patch-flann-1.6.6.diff
+depends_lib         port:hdf5-18
+# MPI support is automatically enabled if hdf5-18 is installed with the +openmpi variant
+configure.args-append ${distname} -DBUILD_MATLAB_BINDINGS=OFF -DUSE_MPI=OFF \
+                    -DMPIEXEC=${prefix}/lib/openmpi/bin/mpiexec \
+                    -DMPI_COMPILER=${prefix}/lib/openmpi/bin/mpic++
 
-patchfiles          patch-CMakeLists.txt.diff patch-cpp-CMakeLists.txt.diff
+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
+}
+variant python27 description {Use python2.6 for python bindings} conflicts python26 python31 python32 {
+    depends_lib-append      port:python27
+    configure.args-append   -DPYTHON_EXECUTABLE=${prefix}/bin/python2.7
+}
+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
+}
+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
+}
 
-livecheck.type  regex
-livecheck.url   ${homepage}
-livecheck.regex Version (\[0-9.\]+)
+livecheck.type      regex
+livecheck.url       ${homepage}
+livecheck.regex     Version (\[0-9.\]+)

Deleted: trunk/dports/science/flann/files/patch-CMakeLists.txt.diff
===================================================================
--- trunk/dports/science/flann/files/patch-CMakeLists.txt.diff	2010-12-21 21:29:15 UTC (rev 74563)
+++ trunk/dports/science/flann/files/patch-CMakeLists.txt.diff	2010-12-21 21:45:54 UTC (rev 74564)
@@ -1,11 +0,0 @@
---- CMakeLists.txt.orig	2010-01-08 12:32:40.000000000 -0600
-+++ CMakeLists.txt	2010-01-08 12:42:06.000000000 -0600
-@@ -2,8 +2,4 @@
- 
- PROJECT( flann )
- 
--set(CMAKE_INSTALL_PREFIX ${PROJECT_SOURCE_DIR}/../build)
--
- ADD_SUBDIRECTORY( cpp )
--ADD_SUBDIRECTORY( matlab )
--ADD_SUBDIRECTORY( python )

Deleted: trunk/dports/science/flann/files/patch-cpp-CMakeLists.txt.diff
===================================================================
--- trunk/dports/science/flann/files/patch-cpp-CMakeLists.txt.diff	2010-12-21 21:29:15 UTC (rev 74563)
+++ trunk/dports/science/flann/files/patch-cpp-CMakeLists.txt.diff	2010-12-21 21:45:54 UTC (rev 74564)
@@ -1,22 +0,0 @@
---- cpp/CMakeLists.txt.orig	2010-01-08 12:51:36.000000000 -0600
-+++ cpp/CMakeLists.txt	2010-01-08 12:55:27.000000000 -0600
-@@ -6,6 +6,7 @@
- SET(SOURCES flann.cpp util/Random.cpp nn/Testing.cpp algorithms/NNIndex.cpp algorithms/dist.cpp util/Logger.cpp)
- 
- ADD_LIBRARY(flann SHARED ${SOURCES})
-+SET_TARGET_PROPERTIES(flann PROPERTIES INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib")
- ADD_LIBRARY(flann_s STATIC ${SOURCES})
- 
- IF(WIN32)
-@@ -17,11 +18,6 @@
-     TARGETS flann
-     RUNTIME DESTINATION python/pyflann/bindings
- )
--ELSE(WIN32)
--INSTALL (
--    TARGETS flann
--    LIBRARY DESTINATION python/pyflann/bindings
--)
- ENDIF(WIN32)
- 
- INSTALL (

Added: trunk/dports/science/flann/files/patch-flann-1.6.6.diff
===================================================================
--- trunk/dports/science/flann/files/patch-flann-1.6.6.diff	                        (rev 0)
+++ trunk/dports/science/flann/files/patch-flann-1.6.6.diff	2010-12-21 21:45:54 UTC (rev 74564)
@@ -0,0 +1,59 @@
+diff -rubw flann-1.6.6-src.orig/cmake/UseLATEX.cmake flann-1.6.6-src/cmake/UseLATEX.cmake
+--- flann-1.6.6-src.orig/cmake/UseLATEX.cmake	2010-12-20 18:52:47.000000000 -0600
++++ flann-1.6.6-src/cmake/UseLATEX.cmake	2010-12-21 09:40:56.000000000 -0600
+@@ -342,9 +342,6 @@
+   FIND_PROGRAM(IMAGEMAGICK_CONVERT convert
+     DOC "The convert program that comes with ImageMagick (available at http://www.imagemagick.org)."
+     )
+-  IF (NOT IMAGEMAGICK_CONVERT)
+-    MESSAGE(SEND_ERROR "Could not find convert program.  Please download ImageMagick from http://www.imagemagick.org and install.")
+-  ENDIF (NOT IMAGEMAGICK_CONVERT)
+ 
+   OPTION(LATEX_SMALL_IMAGES
+     "If on, the raster images will be converted to 1/6 the original size.  This is because papers usually require 600 dpi images whereas most monitors only require at most 96 dpi.  Thus, smaller images make smaller files for web distributation and can make it faster to read dvi files."
+diff -rubw flann-1.6.6-src.orig/cmake/flann_utils.cmake flann-1.6.6-src/cmake/flann_utils.cmake
+--- flann-1.6.6-src.orig/cmake/flann_utils.cmake	2010-12-20 18:52:47.000000000 -0600
++++ flann-1.6.6-src/cmake/flann_utils.cmake	2010-12-21 09:51:11.000000000 -0600
+@@ -52,7 +52,7 @@
+ macro(flann_add_gtest exe)
+     # add build target
+     add_executable(${exe} EXCLUDE_FROM_ALL ${ARGN})
+-    target_link_libraries(${exe} gtest)
++    target_link_libraries(${exe} ${GTEST_LIBRARIES})
+     # add dependency to 'tests' target
+     add_dependencies(tests ${exe})
+ 
+diff -rubw flann-1.6.6-src.orig/src/python/pyflann/io/dat_dataset.py flann-1.6.6-src/src/python/pyflann/io/dat_dataset.py
+--- flann-1.6.6-src.orig/src/python/pyflann/io/dat_dataset.py	2010-12-20 18:52:47.000000000 -0600
++++ flann-1.6.6-src/src/python/pyflann/io/dat_dataset.py	2010-12-21 09:54:14.000000000 -0600
+@@ -28,7 +28,6 @@
+ 
+ from pyflann.exceptions import FLANNException
+ import numpy
+-from scipy.io.numpyio import fwrite
+ 
+ 
+ def is_number(s):
+diff -rubw flann-1.6.6-src.orig/test/CMakeLists.txt flann-1.6.6-src/test/CMakeLists.txt
+--- flann-1.6.6-src.orig/test/CMakeLists.txt	2010-12-20 18:52:48.000000000 -0600
++++ flann-1.6.6-src/test/CMakeLists.txt	2010-12-21 09:51:12.000000000 -0600
+@@ -9,8 +9,8 @@
+ #find_package(Boost COMPONENTS system thread REQUIRED)
+ #target_link_libraries(flann_mt_test ${Boost_SYSTEM_LIBRARY} ${Boost_THREAD_LIBRARY} flann)
+ 
+-find_library(GTEST gtest)
+-if (NOT GTEST)
++find_package(GTest)
++if (NOT GTEST_FOUND)
+ 	message("gtest library not found, some tests will not be run")
+ endif()
+ 
+@@ -23,7 +23,7 @@
+ flann_download_test_data(sift100K.h5 ae2b08f93f3d9f89f5d68566b0406102)
+ flann_download_test_data(sift100K_byte.h5 b772255fd2044e9d2a5a0183953e4705)
+ 
+-if (GTEST AND HDF5_FOUND)
++if (GTEST_FOUND AND HDF5_FOUND)
+     include_directories(${HDF5_INCLUDE_DIR})
+ 	flann_add_gtest(flann_simple_test flann_simple_test.cpp)
+ 	    target_link_libraries(flann_simple_test flann_cpp ${HDF5_LIBRARIES})
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20101221/15d624dd/attachment.html>


More information about the macports-changes mailing list