repo/gentoo:master commit in: dev-python/pyopencl/
"Sam James" <[email protected]>
| Newsgroups | gmane.linux.gentoo.cvs |
|---|---|
| Message-ID | <1787026568.7638cf66e5c70e4fa78a657ee600206187e1fc94.sam@gentoo> |
commit: 7638cf66e5c70e4fa78a657ee600206187e1fc94
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Tue Aug 18 04:12:41 2026 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Aug 18 04:16:08 2026 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7638cf66
dev-python/pyopencl: add 2026.1.2
Closes: https://bugs.gentoo.org/952843
Closes: https://bugs.gentoo.org/962741
Signed-off-by: Sam James <sam <AT> gentoo.org>
dev-python/pyopencl/Manifest | 2 +
dev-python/pyopencl/pyopencl-2026.1.2.ebuild | 80 ++++++++++++++++++++++++++++
2 files changed, 82 insertions(+)
diff --git a/dev-python/pyopencl/Manifest b/dev-python/pyopencl/Manifest
index ef62cfaeeb56..c207909a4045 100644
--- a/dev-python/pyopencl/Manifest
+++ b/dev-python/pyopencl/Manifest
@@ -1,2 +1,4 @@
DIST pyopencl-2025.1.tar.gz 422510 BLAKE2B 1da270b4eabd3cf1209c97db6383ccd3450601946181386c139ed76b9cee3cccba06d6836b342b902fb227d1ef43f899633fe2037f5744a38b37677ef70ed00c SHA512 bc281c38b977f207a213763aca3c0086430e5a4d8d9018673fb5648e1afc440758ec7ec219544644d596805beaa448b2fa34cd5b4c109a46b3d6e8b7648a931c
DIST pyopencl-2025.1.tar.gz.provenance 9183 BLAKE2B 3114192e2e2bcaa202230e2e55245086a020086d09db0ba14c5b48a70bde09defc4d8d1697bc33978fd5b4b6fc902330414078f9ee43aced3d3243392006b3f1 SHA512 7129b058dee923815b487331a7cd29128f88e23feed8c0dfad4d8663bd20575b9f16f22bd97b55d6109d2dfdd2871c899687097b9b2cbb89c816ec27cb555be2
+DIST pyopencl-2026.1.2.tar.gz 445132 BLAKE2B bd59c09eda5977daf75d68fa42cc09d812ebe5c47dab9ac737a1dcbeff40a813319aea83a34c9f5589d16427f96363fd62a315d1eec69188bc177b3af8773efe SHA512 09c5c0595da64d67f27b43cb4d788a78da31e9723be76db09e73d90d4f81337ce8a69dc2fa6968d1e735c7b5a187e7def58c0e9902af989adf4f7c55d6857a67
+DIST pyopencl-2026.1.2.tar.gz.provenance 9312 BLAKE2B 27ac9163e91ed43ba86b08d4c64cadff6d4cbf3cbdb71e1c3d26fbeb41f470df601d52a762e0bc029da6794297bf7c32f2c6dafee7c680d1b23108bbe9c19dd0 SHA512 675922311e2efdedfcc7285491e23d375927e01212729381f73e9b3a985714d982d671863b87221bfc072722b753535b892f6040e8b00d5ec2024e021c8d6a77
diff --git a/dev-python/pyopencl/pyopencl-2026.1.2.ebuild b/dev-python/pyopencl/pyopencl-2026.1.2.ebuild
new file mode 100644
index 000000000000..61d82d0896bd
--- /dev/null
+++ b/dev-python/pyopencl/pyopencl-2026.1.2.ebuild
@@ -0,0 +1,80 @@
+# Copyright 1999-2026 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_EXT=1
+DISTUTILS_USE_PEP517=scikit-build-core
+PYPI_VERIFY_REPO=https://github.com/inducer/pyopencl
+PYTHON_COMPAT=( python3_{12..14} )
+
+inherit distutils-r1 multiprocessing pypi
+
+DESCRIPTION="Python wrapper for OpenCL"
+HOMEPAGE="
+ https://mathema.tician.de/software/pyopencl/
+ https://github.com/inducer/pyopencl/
+ https://pypi.org/project/pyopencl/
+"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc64 ~riscv"
+IUSE="examples opengl"
+
+# Running tests on GPUs requires both appropriate hardware and additional permissions
+# having been granted to the user running them. Testing on CPUs with dev-libs/pocl
+# is in theory possible but has been found to be very fragile, see e.g. Bug #872308.
+RESTRICT="test"
+
+COMMON=">=virtual/opencl-2"
+# libglvnd is only needed for the headers
+DEPEND="
+ ${COMMON}
+ opengl? ( media-libs/libglvnd )
+"
+RDEPEND="
+ ${COMMON}
+ >=dev-python/mako-0.3.6[${PYTHON_USEDEP}]
+ dev-python/numpy[${PYTHON_USEDEP}]
+ >=dev-python/platformdirs-2.2.0[${PYTHON_USEDEP}]
+ >=dev-python/pytools-2025.1.6[${PYTHON_USEDEP}]
+"
+BDEPEND="
+ dev-python/numpy[${PYTHON_USEDEP}]
+ dev-python/nanobind[${PYTHON_USEDEP}]
+ test? ( dev-libs/pocl )
+"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-2025.1-nanobind-flags.patch
+)
+
+EPYTEST_PLUGINS=()
+EPYTEST_XDIST=1
+distutils_enable_tests pytest
+
+python_configure_all() {
+ DISTUTILS_ARGS=(
+ -DPYOPENCL_ENABLE_GL=$(usex opengl)
+ )
+}
+
+python_test() {
+ # Use dev-libs/pocl for testing; ignore any other OpenCL devices that might be present
+ local -x PYOPENCL_TEST="portable:cpu"
+ # Set the number of threads to match MAKEOPTS
+ local -x POCL_MAX_PTHREAD_COUNT=$(makeopts_jobs)
+
+ rm -rf pyopencl || die
+ epytest
+}
+
+python_install_all() {
+ if use examples; then
+ dodoc -r examples
+ docompress -x /usr/share/doc/${PF}/examples
+ fi
+
+ distutils-r1_python_install_all
+}