flann: make it build on Darwin (close #6946)

This commit is contained in:
Luis G. Torres 2015-03-23 08:36:24 -04:00 committed by Vladimír Čunát
parent 60c123560e
commit f7e4be5011
2 changed files with 15 additions and 2 deletions

View file

@ -2,7 +2,7 @@
stdenv.mkDerivation {
name = "flann-1.8.4";
src = fetchurl {
url = http://people.cs.ubc.ca/~mariusm/uploads/FLANN/flann-1.8.4-src.zip;
sha256 = "022w8hph7bli5zbpnk3z1qh1c2sl5hm8fw2ccim651ynn0hr7fyz";
@ -10,11 +10,14 @@ stdenv.mkDerivation {
buildInputs = [ unzip cmake python ];
# patch out examples in Darwin because they do not compile.
patches = stdenv.lib.optionals stdenv.isDarwin [ ./no-examples.patch ];
meta = {
homepage = http://people.cs.ubc.ca/~mariusm/flann/;
license = stdenv.lib.licenses.bsd3;
description = "Fast approximate nearest neighbor searches in high dimensional spaces";
maintainers = with stdenv.lib.maintainers; [viric];
platforms = with stdenv.lib.platforms; linux;
platforms = with stdenv.lib.platforms; linux ++ darwin;
};
}

View file

@ -0,0 +1,10 @@
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -155,7 +155,7 @@
add_subdirectory( cmake )
add_subdirectory( src )
-add_subdirectory( examples )
+#add_subdirectory( examples )
add_subdirectory( test )
add_subdirectory( doc )