testing/hy: build with gpep517

This commit is contained in:
ptrcnull 2024-08-08 20:13:56 +02:00
parent 0db10563f5
commit c4aeea4e9d

View File

@ -2,13 +2,13 @@
# Maintainer: Sören Tempel <soeren+alpine@soeren-tempel.net> # Maintainer: Sören Tempel <soeren+alpine@soeren-tempel.net>
pkgname=hy pkgname=hy
pkgver=0.29.0 pkgver=0.29.0
pkgrel=0 pkgrel=1
pkgdesc="Dialect of Lisp that's embedded in Python" pkgdesc="Dialect of Lisp that's embedded in Python"
url="http://hylang.org/" url="http://hylang.org/"
arch="noarch" arch="noarch"
license="MIT" license="MIT"
depends="python3 py3-funcparserlib py3-rply py3-colorama" depends="python3 py3-funcparserlib py3-rply py3-colorama"
makedepends="py3-setuptools py3-sphinx py3-sphinxcontrib-hydomain py3-sphinx_rtd_theme py3-wheel" makedepends="py3-setuptools py3-sphinx py3-sphinxcontrib-hydomain py3-sphinx_rtd_theme py3-wheel py3-gpep517"
checkdepends="python3-tests py3-pytest py3-pytest-runner py3-tox" checkdepends="python3-tests py3-pytest py3-pytest-runner py3-tox"
options="net" options="net"
subpackages="$pkgname-pyc" subpackages="$pkgname-pyc"
@ -21,7 +21,9 @@ source="$pkgname-$pkgver.tar.gz::https://github.com/hylang/hy/archive/$pkgver.ta
export HY_VERSION="$pkgver" export HY_VERSION="$pkgver"
build() { build() {
python3 setup.py build gpep517 build-wheel \
--wheel-dir .dist \
--output-fd 3 3>&1 >&2
# TODO: Building the documentation requires py3-sphinx == 5.0.2. # TODO: Building the documentation requires py3-sphinx == 5.0.2.
#cd docs #cd docs
@ -29,13 +31,17 @@ build() {
} }
check() { check() {
python3 -m venv --clear --without-pip --system-site-packages .testenv
gpep517 install-wheel --destdir .testenv --prefix '' .dist/*.whl
# Ignore tests requiring binaries to be installed # Ignore tests requiring binaries to be installed
pytest --ignore tests/test_bin.py \ .testenv/bin/python3 -m pytest \
--ignore tests/test_bin.py \
--ignore tests/test_hy2py.py --ignore tests/test_hy2py.py
} }
package() { package() {
python3 setup.py install --skip-build --root="$pkgdir" gpep517 install-wheel --destdir "$pkgdir" \
.dist/*.whl
# XXX: See comment regarding documentation above. # XXX: See comment regarding documentation above.
# local man # local man