diff options
author | Francesco Colista <fcolista@alpinelinux.org> | 2018-05-09 19:01:16 +0000 |
---|---|---|
committer | Francesco Colista <fcolista@alpinelinux.org> | 2018-05-09 19:01:23 +0000 |
commit | 55b50207f4c24e7a4e08aa00be81f7b5d46acd3f (patch) | |
tree | 5bca8db8203b1914a29dde2773e1dfa72efe0d78 /community/py-typing | |
parent | c4e1c82d8b8ff698b84991f9ed1b52c31821127a (diff) | |
download | aports-55b50207f4c24e7a4e08aa00be81f7b5d46acd3f.tar.bz2 aports-55b50207f4c24e7a4e08aa00be81f7b5d46acd3f.tar.xz |
community/py-typing: added py3 package, upgrade to 3.6.4
Diffstat (limited to 'community/py-typing')
-rw-r--r-- | community/py-typing/APKBUILD | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/community/py-typing/APKBUILD b/community/py-typing/APKBUILD new file mode 100644 index 0000000000..2b8613b14c --- /dev/null +++ b/community/py-typing/APKBUILD @@ -0,0 +1,54 @@ +# Contributor: Fabian Affolter <fabian@affolter-engineering.ch> +# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch> +pkgname=py-typing +_pkgname=typing +pkgver=3.6.4 +pkgrel=0 +pkgdesc="Typing – Type Hints for Python" +url="https://pypi.python.org/pypi/typing/" +arch="noarch" +license="PSF" +makedepends="python2-dev python3-dev py-setuptools" +subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" +source="$pkgname-$pkgver.tar.gz::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 + python3 setup.py build +} + +check() { + cd "$builddir" + python2 setup.py test + python3 setup.py test +} + +package() { + mkdir -p "$pkgdir" +} + +_py2() { + replaces="$pkgname" + depends="${depends//py-/py2-}" + _py python2 +} + +_py3() { + depends="${depends//py-/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="f595e0fc395ba13a129ae45681faca7b199fd5c23e8f1573f49e2a6f162b7f2aef680306e76cbf50b978de9f047c674323219981e89c476474295bb8c02211ce py-typing-3.6.4.tar.gz" |