mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-06-08 12:15:02 +02:00
Switch to gpep517 and fix check failure due to removed `setup.py test` command, which was deprecated in setuptools 72.0.0. ``` usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: setup.py --help [cmd1 cmd2 ...] or: setup.py --help-commands or: setup.py cmd --help error: invalid command 'test' ``` Ref: https://gitlab.alpinelinux.org/alpine/aports/-/issues/17110
38 lines
1.2 KiB
Text
38 lines
1.2 KiB
Text
# Contributor: Duncan Bellamy <dunk@denkimushi.com>
|
|
# Maintainer: Duncan Bellamy <dunk@denkimushi.com>
|
|
pkgname=py3-repoze-lru
|
|
_pkgname=repoze.lru
|
|
pkgver=0.7
|
|
pkgrel=7
|
|
pkgdesc="A tiny LRU cache implementation and decorator"
|
|
url="https://repoze.readthedocs.io/en/latest/"
|
|
arch="noarch"
|
|
license="custom"
|
|
depends="python3"
|
|
makedepends="py3-gpep517 py3-setuptools py3-wheel"
|
|
subpackages="$pkgname-doc $pkgname-pyc"
|
|
source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/r/repoze.lru/repoze.lru-$pkgver.tar.gz"
|
|
builddir="$srcdir/$_pkgname-$pkgver"
|
|
|
|
build() {
|
|
gpep517 build-wheel \
|
|
--wheel-dir .dist \
|
|
--output-fd 3 3>&1 >&2
|
|
}
|
|
|
|
check() {
|
|
mv repoze backup
|
|
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
|
.testenv/bin/python3 -m installer .dist/*.whl
|
|
.testenv/bin/python3 -m unittest -v
|
|
mv backup repoze
|
|
}
|
|
|
|
package() {
|
|
python3 -m installer -d "$pkgdir" \
|
|
.dist/*.whl
|
|
install -Dm644 "$builddir"/LICENSE.txt \
|
|
"$pkgdir"/usr/share/licenses/$pkgname/LICENSE
|
|
}
|
|
|
|
sha512sums="c4d8b015931c4265fa8559f99c9d5016835574b368ebe0d49fe503afe908020b2bf29836606134e00c6c0aa436d52a00bb73d6ab80e98d0802f54bd2e4686476 py3-repoze-lru-0.7.tar.gz"
|