1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
5 PYTHON_COMPAT=( python2_7 )
7 inherit autotools python-single-r1
9 DESCRIPTION="IlmBase Python bindings"
10 HOMEPAGE="https://www.openexr.com"
11 SRC_URI="https://github.com/openexr/openexr/releases/download/v${PV}/${P}.tar.gz"
18 REQUIRED_USE="${PYTHON_REQUIRED_USE}"
20 RDEPEND="${PYTHON_DEPS}
21 ~media-libs/ilmbase-${PV}:=
22 $(python_gen_cond_dep '
23 >=dev-libs/boost-1.62.0-r1[python(+),${PYTHON_MULTI_USEDEP}]
26 dev-python/numpy-python2[${PYTHON_MULTI_USEDEP}]
27 >=dev-python/numpy-1.10.4[${PYTHON_MULTI_USEDEP}]
33 >=virtual/pkgconfig-0-r1"
36 "${FILESDIR}/${P}-link-pyimath.patch"
37 "${FILESDIR}/${P}-fix-build-system.patch"
48 local boostpython_ver="${EPYTHON:6}"
49 if has_version ">=dev-libs/boost-1.70.0"; then
50 boostpython_ver="${boostpython_ver/./}"
52 boostpython_ver="-${boostpython_ver}"
56 --with-boost-include-dir="${EPREFIX}/usr/include/boost"
57 --with-boost-lib-dir="${EPREFIX}/usr/$(get_libdir)"
58 --with-boost-python-libname="boost_python${boostpython_ver}"
62 econf "${myeconfargs[@]}"
66 # Fails to install with multiple jobs
67 emake DESTDIR="${D}" -j1 install
71 # package provides pkg-config files
72 find "${D}" -name '*.la' -delete || die