paraports

parazyd's aports
git clone git://parazyd.org/paraports.git | https://git.parazyd.org/paraports
Log | Files | Refs | README | LICENSE

commit 86faa43a3662d4e8b9d6e0fd9fd2794d8bbe0599
parent 46e84b6507af0b93a0ddbc08b68bd0996e66e29e
Author: parazyd <parazyd@dyne.org>
Date:   Tue, 11 Jun 2019 01:15:56 +0200

Add py-bjoern.

Diffstat:
Apy-bjoern/APKBUILD | 46++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 46 insertions(+), 0 deletions(-)

diff --git a/py-bjoern/APKBUILD b/py-bjoern/APKBUILD @@ -0,0 +1,46 @@ +# Maintainer: Ivan J. <parazyd@dyne.org> +pkgname=py-bjoern +_pkgname=bjoern +pkgver=3.0.1 +pkgrel=0 +pkgdesc="A screamingly fast Python WSGI server written in C" +url="https://github.com/jonashaag/bjoern" +arch="x86_64" +license="BSD" +depends="http-parser libev" +makedepends="python2-dev python3-dev py-setuptools http-parser-dev libev-dev" +subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" +source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz" +builddir="$srcdir/$_pkgname-$pkgver" + +build() { + cd "$builddir" + + python2 setup.py build || return 1 + python3 setup.py build || return 1 +} + +package() { + mkdir -p "$pkgdir" +} + +_py2() { + replaces="$pkgname" + _py python2 +} + +_py3() { + _py python3 +} + +_py() { + local python="$1" + pkgdesc="$pkgdesc (for $python)" + depends="$depends $python" + install_if="$pkgname=$pkgver-r$pkgrel $python" + + cd "$builddir" + $python setup.py install --prefix=/usr --root="$subpkgdir" +} + +sha512sums="7213e237097ce4d7d2b9c5061739ca0b1a54144e48777990f4bc180762712ccad8383efae76d6ce61da954238fef134da76377041a79b7962200826eec63eb16 bjoern-3.0.1.tar.gz"