aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--main/py-gnutls/APKBUILD42
1 files changed, 27 insertions, 15 deletions
diff --git a/main/py-gnutls/APKBUILD b/main/py-gnutls/APKBUILD
index 6afb5697a6..2ebe07b1c5 100644
--- a/main/py-gnutls/APKBUILD
+++ b/main/py-gnutls/APKBUILD
@@ -1,30 +1,42 @@
-# Contributor: Francesco Colista <francesco.colista@gmail.com>
-# Maintainer: Francesco Colista <francesco.colista@gmail.com>
+# Contributor: Francesco Colista <fcolista@alpinelinux.org>
+# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=py-gnutls
_pkgname=python-gnutls
-pkgver=2.0.1
+pkgver=3.0.0
pkgrel=0
pkgdesc="Python wrapper for the GNUTLS library"
url="http://pypi.python.org/pypi/python-gnutls"
-arch="all"
+arch="noarch"
license="PSF"
-depends=""
-makedepends="python-dev gnutls-dev"
+makedepends="python2-dev gnutls-dev py-setuptools"
install=""
-subpackages=""
+subpackages="py2-${pkgname/py-/}:_py2"
source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
-_buildroot=${srcdir}/${_pkgname}-${pkgver}
+builddir=${srcdir}/${_pkgname}-${pkgver}
+
build() {
- cd ${_buildroot}
- python setup.py build || return 1
+ cd "$builddir"
+ python2 setup.py build || return 1
}
package() {
- cd ${_buildroot}
- python setup.py install --root="$pkgdir" || return 1
+ 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
+ replaces="$pkgname"
}
-md5sums="adba310851a15d19ff29355385c6f74f python-gnutls-2.0.1.tar.gz"
-sha256sums="d8fb368c6a4dd58bc6cd5e61d4a12d119c4506fd344a371b3429b3ac2623b9ac python-gnutls-2.0.1.tar.gz"
-sha512sums="6dca8ba9e98e76add30502825f5711e3bc6f22b2a1e28416a3c1acacec41eb45e4e2f63c0185fa10f8e518df41f1093ba33ab33a5f69dd25300e17db1022b3df python-gnutls-2.0.1.tar.gz"
+md5sums="bea3c2452ed3e92b2c58c62b0d8b5ea0 python-gnutls-3.0.0.tar.gz"
+sha256sums="6c1274c9f5c0c8c18d050134d6aa2bff3dbf59349fe5485f447fff5c24eb2dfb python-gnutls-3.0.0.tar.gz"
+sha512sums="cc45ae1425db2f742bde997e4e4ebbb630cde51978fbf0dcbe6dda0a9d96a9d4c43cc224c54a6a300e95d0ff8b81fb069f04007125992472aa277a0db3c2070a python-gnutls-3.0.0.tar.gz"