43 lines
1.2 KiB
Text
43 lines
1.2 KiB
Text
# Maintainer: Patrycja Rosa <alpine@ptrcnull.me>
|
|
pkgname=py3-a2wsgi
|
|
pkgver=1.7.0
|
|
pkgrel=0
|
|
pkgdesc="Convert WSGI app to ASGI app or ASGI app to WSGI app"
|
|
url="https://github.com/abersheeran/a2wsgi"
|
|
arch="noarch"
|
|
license="Apache-2.0"
|
|
depends="python3"
|
|
makedepends="py3-gpep517 py3-pdm-backend py3-wheel"
|
|
checkdepends="py3-pytest py3-httpx py3-pytest-asyncio"
|
|
subpackages="$pkgname-pyc"
|
|
source="https://github.com/abersheeran/a2wsgi/archive/refs/tags/v$pkgver/a2wsgi-$pkgver.tar.gz
|
|
pdm-backend.patch
|
|
"
|
|
builddir="$srcdir/a2wsgi-$pkgver"
|
|
|
|
case "$CARCH" in
|
|
# test suite blocked by py3-httpx
|
|
armhf|ppc64le) options="!check" ;;
|
|
esac
|
|
|
|
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
|
|
}
|
|
|
|
sha512sums="
|
|
010776279c7f2ceaa580395c226788ea72e14726cde8e3adb8304e9bd887d55736c5985ebd8055dfd48a15632543497e10163040ba677ffeddbd3d2e02e24440 a2wsgi-1.7.0.tar.gz
|
|
bb60783941b7308a82a87b058c571067ad4c26f3b605e717c87dca9f52f9457a1e72ba9ca56556ea3fb63789cbdcca46a67bfadf2bd4873d713ffbcfd3190a9c pdm-backend.patch
|
|
"
|