mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-06-07 22:14:28 +02:00
53 lines
1.4 KiB
Text
53 lines
1.4 KiB
Text
# Contributor: Stuart Cardall <developer@it-offshore.co.uk>
|
|
# Maintainer: Stuart Cardall <developer@it-offshore.co.uk>
|
|
pkgname=py3-opencl
|
|
_pkgreal=pyopencl
|
|
pkgver=2025.1
|
|
pkgrel=0
|
|
pkgdesc="Python3 wrapper for OpenCL"
|
|
url="https://pypi.org/project/pyopencl"
|
|
arch="all"
|
|
license="MIT"
|
|
depends="py3-platformdirs py3-numpy py3-mako py3-pytools"
|
|
makedepends="
|
|
libffi-dev
|
|
mesa-dev
|
|
opencl-dev
|
|
py3-gpep517
|
|
py3-nanobind
|
|
py3-numpy-dev
|
|
py3-scikit-build-core
|
|
python3-dev
|
|
"
|
|
checkdepends="py3-pytest py3-py py3-mako"
|
|
subpackages="$pkgname-pyc"
|
|
source="https://files.pythonhosted.org/packages/source/${_pkgreal:0:1}/$_pkgreal/$_pkgreal-$pkgver.tar.gz"
|
|
builddir="$srcdir/$_pkgreal-$pkgver"
|
|
# check: requires OpenCL platform
|
|
options="!check"
|
|
|
|
replaces="py-opencl" # Backwards compatibility
|
|
provides="py-opencl=$pkgver-r$pkgrel" # Backwards compatibility
|
|
|
|
build() {
|
|
gpep517 build-wheel \
|
|
--wheel-dir .dist \
|
|
--output-fd 3 3>&1 >&2
|
|
}
|
|
|
|
check() {
|
|
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
|
.testenv/bin/python3 -m installer .dist/*.whl
|
|
.testenv/bin/python3 -m pytest
|
|
}
|
|
|
|
package() {
|
|
python3 -m installer -d "$pkgdir" \
|
|
.dist/*.whl
|
|
# Remove incorrectly installed files
|
|
find "$pkgdir" \( -name .gitignore -o -name pyproject.toml \) -delete
|
|
}
|
|
|
|
sha512sums="
|
|
bc281c38b977f207a213763aca3c0086430e5a4d8d9018673fb5648e1afc440758ec7ec219544644d596805beaa448b2fa34cd5b4c109a46b3d6e8b7648a931c pyopencl-2025.1.tar.gz
|
|
"
|