backports/py3-numpy-stl: move to gpep517

This commit is contained in:
Antoine Martin 2024-11-01 10:11:09 -04:00
parent 74c4c19621
commit bd882e36a2
Signed by: forge
GPG key ID: D62A472A4AA7D541

View file

@ -1,32 +1,37 @@
# Contributor: Aiden Grossman <agrossman154@yahoo.com> # Contributor: Aiden Grossman <agrossman154@yahoo.com>
# Maintainer: Aiden Grossman <agrossman154@yahoo.com> # Maintainer:
pkgname=py3-numpy-stl pkgname=py3-numpy-stl
pkgver=3.0.1 pkgver=3.0.1
pkgrel=2 pkgrel=4
pkgdesc="Library for working with STLs" pkgdesc="Library for working with STLs"
url="https://github.com/WoLpH/numpy-stl" url="https://github.com/WoLpH/numpy-stl"
# s390x: no py3-utils # s390x: no py3-utils
arch="noarch !s390x" arch="noarch !s390x"
license="BSD-3-Clause" license="BSD-3-Clause"
depends="python3 py3-utils py3-numpy" depends="python3 py3-utils py3-numpy"
makedepends="py3-setuptools" makedepends="py3-setuptools py3-gpep517"
checkdepends="py3-pytest" checkdepends="py3-pytest"
subpackages="$pkgname-pyc" subpackages="$pkgname-pyc"
source="$pkgname-$pkgver.tar.gz::https://github.com/wolph/numpy-stl/releases/download/v$pkgver/numpy-stl-$pkgver.tar.gz" source="$pkgname-$pkgver.tar.gz::https://github.com/wolph/numpy-stl/releases/download/v$pkgver/numpy-stl-$pkgver.tar.gz"
builddir="$srcdir/numpy-stl-$pkgver" builddir="$srcdir/numpy-stl-$pkgver"
build() { build() {
python3 setup.py build gpep517 build-wheel \
--wheel-dir .dist \
--output-fd 3 3>&1 >&2
} }
check() { check() {
python3 -m venv --clear --without-pip --system-site-packages .testenv
gpep517 install-wheel --destdir .testenv --prefix '' .dist/*.whl
# deselected test needs xvfb-run and fails # deselected test needs xvfb-run and fails
pytest \ .testenv/bin/python3 -m pytest \
--deselect tests/test_ascii.py::test_use_with_qt_with_custom_locale_decimal_delimeter --deselect tests/test_ascii.py::test_use_with_qt_with_custom_locale_decimal_delimeter
} }
package() { package() {
python3 setup.py install --skip-build --root="$pkgdir" gpep517 install-wheel --destdir "$pkgdir" \
.dist/*.whl
} }
sha512sums=" sha512sums="