diff options
Diffstat (limited to 'community/py-service_identity/APKBUILD')
-rw-r--r-- | community/py-service_identity/APKBUILD | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/community/py-service_identity/APKBUILD b/community/py-service_identity/APKBUILD new file mode 100644 index 0000000000..15dc789f7c --- /dev/null +++ b/community/py-service_identity/APKBUILD @@ -0,0 +1,50 @@ +# Contributor: Francesco Colista <fcolista@alpinelinux.org> +# Maintainer: Francesco Colista <fcolista@alpinelinux.org> +pkgname=py-service_identity +_pkgname=service_identity +pkgver=16.0.0 +pkgrel=0 +pkgdesc="Service Identity Verification for pyOpenSSL" +url="https://service-identity.readthedocs.org/" +arch="noarch" +license="MIT" +depends="" +makedepends="python2-dev py-setuptools py2-pytest python3-dev py3-pytest" +install="" +subpackages="py3-${pkgname/py-/}:_py3 py2-${pkgname/py-/}:_py2" +source="https://files.pythonhosted.org/packages/source/s/$_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" +} + +_py() { + local python=$1 + pkgdesc="$pkgdesc - $python" + install_if="$pkgname=$pkgver-r$pkgrel $python" + cd "$builddir" + $python setup.py install --prefix=/usr --root="$subpkgdir" +} + +_py2() { + _py python2 + depends="py2-asn1 py2-asn1-modules py2-openssl py2-characteristic" + replaces="$pkgname" +} + +_py3() { + _py python3 + depends="py3-asn1 py3-asn1-modules py3-openssl py3-characteristic" +} + +md5sums="d52392597b9c44a740abf322bfdb21e6 service_identity-16.0.0.tar.gz" +sha256sums="0630e222f59f91f3db498be46b1d879ff220955d7bbad719a5cb9ad14e3c3036 service_identity-16.0.0.tar.gz" +sha512sums="0ffa28b3dece2415a058ec159e4f85f3e86c0de520ed5d6933ec49edca91ccc79a57893ace40d5441455791433828ab55a939e90335dfdee8582627e33a896ae service_identity-16.0.0.tar.gz" |