summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas K. Hüttel <dilfridge@gentoo.org>2012-02-19 22:34:54 +0000
committerAndreas K. Hüttel <dilfridge@gentoo.org>2012-02-19 22:34:54 +0000
commitdb54d7ae6f9b4a9884d13a5abeaf654f5fd353d8 (patch)
tree5e71521a4ee3fa82b14c089a62a0c8fdc6d0eca1 /sci-libs/flann
parentBug #404573: Move net-wireless/{wispy-,spec}tools. (diff)
downloadgentoo-2-db54d7ae6f9b4a9884d13a5abeaf654f5fd353d8.tar.gz
gentoo-2-db54d7ae6f9b4a9884d13a5abeaf654f5fd353d8.tar.bz2
gentoo-2-db54d7ae6f9b4a9884d13a5abeaf654f5fd353d8.zip
Version bump. Needs still implementation of cuda support.
(Portage version: 2.1.10.47/cvs/Linux x86_64)
Diffstat (limited to 'sci-libs/flann')
-rw-r--r--sci-libs/flann/ChangeLog9
-rw-r--r--sci-libs/flann/flann-1.7.1.ebuild84
2 files changed, 91 insertions, 2 deletions
diff --git a/sci-libs/flann/ChangeLog b/sci-libs/flann/ChangeLog
index 21007e10abd4..3fe4964db0cf 100644
--- a/sci-libs/flann/ChangeLog
+++ b/sci-libs/flann/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for sci-libs/flann
-# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sci-libs/flann/ChangeLog,v 1.12 2011/11/11 20:12:59 vapier Exp $
+# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/sci-libs/flann/ChangeLog,v 1.13 2012/02/19 22:34:54 dilfridge Exp $
+
+*flann-1.7.1 (19 Feb 2012)
+
+ 19 Feb 2012; Andreas K. Huettel <dilfridge@gentoo.org> +flann-1.7.1.ebuild:
+ Version bump. Needs still implementation of cuda support.
11 Nov 2011; Mike Frysinger <vapier@gentoo.org> flann-1.6.8.ebuild,
flann-1.6.10.ebuild, flann-1.6.11.ebuild:
diff --git a/sci-libs/flann/flann-1.7.1.ebuild b/sci-libs/flann/flann-1.7.1.ebuild
new file mode 100644
index 000000000000..8a22e892cda9
--- /dev/null
+++ b/sci-libs/flann/flann-1.7.1.ebuild
@@ -0,0 +1,84 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sci-libs/flann/flann-1.7.1.ebuild,v 1.1 2012/02/19 22:34:54 dilfridge Exp $
+
+EAPI=3
+
+PYTHON_DEPEND="python? 2:2.5"
+
+inherit cmake-utils eutils python
+
+DESCRIPTION="Library for performing fast approximate nearest neighbor searches in high dimensional spaces"
+HOMEPAGE="http://www.cs.ubc.ca/~mariusm/index.php/FLANN/FLANN/"
+SRC_URI="http://people.cs.ubc.ca/~mariusm/uploads/FLANN/${P}-src.zip
+ test? ( http://dev.gentoo.org/~dilfridge/distfiles/${PN}-1.6.10-testdata.tar.xz )"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="doc mpi octave python static-libs test"
+# cuda needs to be implemented!
+
+RDEPEND="sci-libs/hdf5[mpi?]
+ mpi? ( dev-libs/boost[mpi] )
+ octave? ( sci-mathematics/octave )
+ python? ( dev-python/numpy )"
+DEPEND="${RDEPEND}
+ app-arch/unzip
+ test? ( dev-cpp/gtest )"
+
+S="${WORKDIR}"/${P}-src
+
+src_prepare() {
+ # bug #302621
+ has_version sci-libs/hdf5[mpi] && export CXX=mpicxx
+ # gentoo doc directory respected
+ sed -i \
+ -e "s:share/doc/flann:share/doc/${PF}:" \
+ doc/CMakeLists.txt || die
+ # python standard installation directory respected
+ sed -i \
+ -e "/share/d" \
+ -e "/COMMAND/s:install:install --root="${ED}" --no-compile:" \
+ src/python/CMakeLists.txt || die
+ # produce pure octave files
+ # octave gentoo installation for .m files respected
+ sed -i \
+ -e 's/--mex//' \
+ -e 's/\.mex/\.oct/' \
+ -e '/FILES/s/${MEX_FILE}//' \
+ -e 's:share/flann/octave:share/octave/site/m:' \
+ -e "/CUSTOM_TARGET/a\INSTALL(FILES \${MEX_FILE} DESTINATION libexec/octave/site/oct/${CHOST})" \
+ src/matlab/CMakeLists.txt || die
+ # do not compile examples by default
+ sed -i \
+ -e '/add_subdirectory.*examples/d' \
+ CMakeLists.txt || die
+ # compile tests only when requested
+ use test || sed -i -e '/add_subdirectory.*test/d' CMakeLists.txt
+ # avoid automatic installation of pdf
+ use doc || sed -i -e '/doc/d' CMakeLists.txt
+}
+
+src_configure() {
+ local mycmakeargs=(
+ "-DBUILD_C_BINDINGS=ON"
+ "-DBUILD_CUDA_LIB=OFF"
+ $(cmake-utils_use_build octave MATLAB_BINDINGS)
+ $(cmake-utils_use_build python PYTHON_BINDINGS)
+ $(cmake-utils_use_use mpi)
+ )
+ cmake-utils_src_configure
+}
+
+src_test() {
+ cd "${CMAKE_BUILD_DIR}"
+ LD_LIBRARY_PATH="${PWD}/lib" PYTHONPATH="${S}/src/python" \
+ emake test
+}
+
+src_install() {
+ cmake-utils_src_install
+ dodoc README.md
+ use static-libs || find "${ED}" -name 'lib*.a' -exec rm -rf '{}' '+'
+}