diff options
Diffstat (limited to 'dev-libs/libdynd/libdynd-0.7.2.ebuild')
-rw-r--r-- | dev-libs/libdynd/libdynd-0.7.2.ebuild | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/dev-libs/libdynd/libdynd-0.7.2.ebuild b/dev-libs/libdynd/libdynd-0.7.2.ebuild new file mode 100644 index 000000000000..37b608c9f81e --- /dev/null +++ b/dev-libs/libdynd/libdynd-0.7.2.ebuild @@ -0,0 +1,67 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=6 + +inherit cmake-utils cuda + +DESCRIPTION="C++ dynamic multi-dimensionnal array library with Python exposure" +HOMEPAGE="http://libdynd.org" +SRC_URI="https://github.com/libdynd/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="BSD" +SLOT="0/${PV}" +KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" +IUSE="cuda doc fftw mkl test" + +RDEPEND=" + dev-libs/c-blosc:0= + cuda? ( dev-util/nvidia-cuda-toolkit ) + fftw? ( sci-libs/fftw:3.0 ) +" +DEPEND="${RDEPEND} + doc? ( app-doc/doxygen[dot] ) +" + +DOCS=( README.md ) + +src_prepare() { + #use cuda && cuda_src_prepare + cmake-utils_src_prepare + cmake_comment_add_subdirectory examples + # fix forced cxxflags and doc installation directory + sed -e 's|-O3 -fomit-frame-pointer||' \ + -e 's|-Werror||g' \ + -e "s|docs DESTINATION docs|docs/html DESTINATION share/doc/${PF}|" \ + -i CMakeLists.txt || die + # don't install test exec + sed -e 's|install(TARGETS test_libdynd||' \ + -e 's|RUNTIME DESTINATION bin)||' \ + -i tests/CMakeLists.txt || die + # not tested + if use mkl; then + sed -e "s|/opt/intel/.*|$(ls -1d ${EPREFIX}/opt/intel/compilers*)|" \ + -i tests/CMakeLists.txt || die + fi +} + +src_configure() { + local mycmakeargs=( + -DDYND_INSTALL_LIB=ON + -DDYND_SHARED_LIB=ON + -DDYND_BUILD_BENCHMARKS=OFF + -DDYND_BUILD_DOCS="$(usex doc)" + -DDYND_BUILD_PLUGIN="$(usex mkl)" + -DDYND_BUILD_TESTS="$(usex test)" + -DDYND_CUDA="$(usex cuda)" + -DDYND_FFTW="$(usex fftw)" + -DFFTW_PATH="${EPREFIX}/usr" + ) + cmake-utils_src_configure +} + +src_test() { + cd "${BUILD_DIR}" || die + ./tests/test_libdynd || die +} |