1 # Copyright 1999-2017 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
5 PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
7 inherit cmake-utils flag-o-matic python-single-r1 versionator
9 DESCRIPTION="Libs for the efficient manipulation of volumetric data"
10 HOMEPAGE="http://www.openvdb.org"
11 SRC_URI="https://github.com/dreamworksanimation/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz
12 https://github.com/dracwyrm/gentoo-patches/raw/master/${PN}/${P}-patchset-01.tar.xz"
16 KEYWORDS="~amd64 ~x86"
17 IUSE="+abi3-compat doc python"
18 REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
20 RDEPEND="sys-libs/zlib:=
21 >=dev-libs/boost-1.62:=[python?,${PYTHON_USEDEP}]
29 >=dev-libs/c-blosc-1.5.0
33 dev-python/numpy[${PYTHON_USEDEP}]
39 doc? ( app-doc/doxygen[latex] )"
42 "${WORKDIR}/0001-Change-hardcoded-paths-to-GNUInstallDirs-variables.patch"
43 "${WORKDIR}/0002-Use-PkgConfig-to-find-IlmBase-and-OpenEXR.patch"
44 "${WORKDIR}/0003-Boost-1.65-NumPy-support.patch"
48 use python && python-single-r1_pkg_setup
52 local myprefix="${EPREFIX}/usr/"
54 # To stay in sync with Boost
55 append-cxxflags -std=c++14
58 -DOPENVDB_BUILD_UNITTESTS=OFF
59 -DOPENVDB_BUILD_DOCS=$(usex doc)
60 -DCMAKE_INSTALL_DOCDIR="share/doc/${PF}"
61 -DOPENVDB_BUILD_PYTHON_MODULE=$(usex python)
62 -DOPENVDB_ENABLE_3_ABI_COMPATIBLE=$(usex abi3-compat)
63 -DOPENVDB_ENABLE_RPATH=OFF
65 -DBLOSC_LOCATION="${myprefix}"
66 -DGLEW_LOCATION="${myprefix}"
67 -DGLFW3_LOCATION="${myprefix}"
68 -DTBB_LOCATION="${myprefix}"
71 use python && mycmakeargs+=( -DPYOENVDB_INSTALL_DIRECTORY=${python_get_sitedir} )
73 cmake-utils_src_configure