mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-24 19:55:26 +03:00
46 lines
1.5 KiB
Text
46 lines
1.5 KiB
Text
# Contributor: Michał Polański <michal@polanski.me>
|
|
# Maintainer: Michał Polański <michal@polanski.me>
|
|
pkgname=py3-httptools
|
|
pkgver=0.3.0
|
|
pkgrel=0
|
|
pkgdesc="Fast HTTP parser"
|
|
url="https://github.com/MagicStack/httptools"
|
|
license="MIT"
|
|
arch="all"
|
|
depends="python3"
|
|
makedepends="py3-setuptools python3-dev cython http-parser-dev"
|
|
checkdepends="py3-pytest py3-aiohttp py3-openssl py3-psutil"
|
|
source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/h/httptools/httptools-$pkgver.tar.gz
|
|
$pkgname-$pkgver.tar.gz.noauto::https://github.com/MagicStack/httptools/archive/refs/tags/v$pkgver.tar.gz"
|
|
builddir="$srcdir/httptools-$pkgver"
|
|
|
|
prepare() {
|
|
default_prepare
|
|
|
|
# PyPI tarball contains required vendored dependency of llhttp
|
|
# (kept at an older version), but GitHub tarball has the tests
|
|
mkdir tests
|
|
tar xvf "$srcdir"/$pkgname-$pkgver.tar.gz.noauto \
|
|
--strip-components=1 \
|
|
httptools-$pkgver/tests
|
|
|
|
# use system http-parser
|
|
rm -r vendor/http-parser
|
|
}
|
|
|
|
build() {
|
|
python3 setup.py build build_ext --inplace --use-system-http-parser
|
|
}
|
|
|
|
check() {
|
|
pytest
|
|
}
|
|
|
|
package() {
|
|
python3 setup.py install --root="$pkgdir" --skip-build
|
|
}
|
|
|
|
sha512sums="
|
|
37a87aadd30b73e4a861599ad9a37edbfaa1bdafbfa0ebf8cda2386272d0eb24b160f106fc283877b1c9992066e31c7fb1f87913e9da4a5a517807b337b7442c py3-httptools-0.3.0.tar.gz
|
|
7efc2f09baa4b50cb69314066dcd131e46f38f91cb256117024cbf31d3ddecb9e5f8fd3dbe9ead13b4954ad48f632df9c67cab90d6b414032583a5f5a38e5ca9 py3-httptools-0.3.0.tar.gz.noauto
|
|
"
|