Gentoo Archives: gentoo-commits

From: Marek Szuba <marecki@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pyopencl/
Date: Thu, 01 Jul 2021 11:02:45
Message-Id: 1625137336.58e7d2e06f0a8e26dedd37f8acb057c52e03d923.marecki@gentoo
1 commit: 58e7d2e06f0a8e26dedd37f8acb057c52e03d923
2 Author: Marek Szuba <marecki <AT> gentoo <DOT> org>
3 AuthorDate: Thu Jul 1 09:58:59 2021 +0000
4 Commit: Marek Szuba <marecki <AT> gentoo <DOT> org>
5 CommitDate: Thu Jul 1 11:02:16 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=58e7d2e0
7
8 dev-python/pyopencl: bump to 2021.2.5 and EAPI 8
9
10 Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>
11
12 dev-python/pyopencl/Manifest | 1 +
13 dev-python/pyopencl/pyopencl-2021.2.5.ebuild | 55 ++++++++++++++++++++++++++++
14 2 files changed, 56 insertions(+)
15
16 diff --git a/dev-python/pyopencl/Manifest b/dev-python/pyopencl/Manifest
17 index 6bc449246b7..6e103b99195 100644
18 --- a/dev-python/pyopencl/Manifest
19 +++ b/dev-python/pyopencl/Manifest
20 @@ -1,2 +1,3 @@
21 DIST pyopencl-2021.1.3.tar.gz 447070 BLAKE2B fcd8c5d06de9c14a7bcf3c3d37f89cb208adf0225cc88a081aefc86aac82a99026183f2c9975f34cd8247f784335e4ba6c0a09164ce01e527123b5c1dd952a76 SHA512 8799e73b3b1596387f619fd997f643228679fb1d9ab5ce6704da9df51922f96229efc98ab6b7a7361234848078b15bc67946a4188f4d17cb8760040b48b346e8
22 DIST pyopencl-2021.2.3.tar.gz 450895 BLAKE2B 0395ee6ef32baa57fe9df0c9960f5d761cfced1cc8b87e51e7ebcc7cda6a6b651fc491acf6be525239576fedec2a8375935799fc77568e131dcb26436a59c6f1 SHA512 41ef44eac0112ceac15c1260198a0bd642c244f3ad45aa1d7feba70b55a3f257ce01f7c5a8eaf2ce1df263492452055286caad004101d8bdb2d4f7307fb339be
23 +DIST pyopencl-2021.2.5.tar.gz 449527 BLAKE2B 922970c6aa93d2ce600c1e107fa3303c42bd44a264f7c38b30c8d2c909ec12e4cf8fa21dbaffa558c7b183141802ac13fe1a1032230b611b56503cfbaeae40c1 SHA512 a8784e0c6ae9a3c2d8f463405d5bbfe4ac1df138fd5f1ca8ce622afaab787333574c6ee8f4a828c09dc36c1b7a5df8fbe5d70e2236be32d457c3e1cbdeb880e5
24
25 diff --git a/dev-python/pyopencl/pyopencl-2021.2.5.ebuild b/dev-python/pyopencl/pyopencl-2021.2.5.ebuild
26 new file mode 100644
27 index 00000000000..9c4b6ac92a7
28 --- /dev/null
29 +++ b/dev-python/pyopencl/pyopencl-2021.2.5.ebuild
30 @@ -0,0 +1,55 @@
31 +# Copyright 1999-2021 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=8
35 +
36 +PYTHON_COMPAT=( python3_{8..10} )
37 +
38 +inherit distutils-r1
39 +
40 +DESCRIPTION="Python wrapper for OpenCL"
41 +HOMEPAGE="https://mathema.tician.de/software/pyopencl/
42 + https://pypi.org/project/pyopencl/"
43 +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
44 +
45 +LICENSE="GPL-2"
46 +SLOT="0"
47 +KEYWORDS="~amd64"
48 +IUSE="examples opengl"
49 +
50 +COMMON="dev-python/numpy[${PYTHON_USEDEP}]
51 + >=virtual/opencl-2"
52 +RDEPEND="${COMMON}
53 + >=dev-python/appdirs-1.4.0[${PYTHON_USEDEP}]
54 + dev-python/mako[${PYTHON_USEDEP}]
55 + >=dev-python/pytools-2021.2.7[${PYTHON_USEDEP}]"
56 +DEPEND="${COMMON}
57 + dev-python/pybind11[${PYTHON_USEDEP}]
58 + opengl? ( media-libs/libglvnd )"
59 +
60 +# The test suite fails if there are no OpenCL platforms available, and
61 +# even if there is one (which requires the presence of both an OpenCL
62 +# runtime *and* hardware supported by it - simply emerging any runtime
63 +# is not enough) the vast majority of tests end up skipped because by
64 +# default the portage user hasn't got sufficient privileges to talk
65 +# to the GPU.
66 +RESTRICT="test"
67 +
68 +python_configure_all() {
69 + local myconf=()
70 + if use opengl; then
71 + myconf+=(--cl-enable-gl)
72 + fi
73 +
74 + "${EPYTHON}" configure.py \
75 + "${myconf[@]}"
76 +}
77 +
78 +python_install_all() {
79 + if use examples; then
80 + dodoc -r examples
81 + docompress -x /usr/share/doc/${PF}/examples
82 + fi
83 +
84 + distutils-r1_python_install_all
85 +}