[alpine-aports,v4,4/5] main/py3-werkzeug: drop py2, update to 0.15.4

Message ID 20190709220339.14866-5-sir@cmpwn.com
State New
Headers show
Series
  • main/py3-flask: drop py2, upgrade
Related show

Commit Message

Drew DeVault July 9, 2019, 10:03 p.m. UTC
---
 main/py-werkzeug/APKBUILD  | 47 --------------------------------------
 main/py3-werkzeug/APKBUILD | 31 +++++++++++++++++++++++++
 2 files changed, 31 insertions(+), 47 deletions(-)
 delete mode 100644 main/py-werkzeug/APKBUILD
 create mode 100644 main/py3-werkzeug/APKBUILD

Patch

diff --git a/main/py-werkzeug/APKBUILD b/main/py-werkzeug/APKBUILD
deleted file mode 100644
index b42d223b48..0000000000
--- a/main/py-werkzeug/APKBUILD
+++ /dev/null
@@ -1,47 +0,0 @@ 
-# Contributor:
-# Maintainer: prspkt <prspkt@protonmail.com>
-pkgname=py-werkzeug
-_pkgname=Werkzeug
-pkgver=0.14.1
-pkgrel=1
-pkgdesc="The WSGI swiss-army knife"
-url="http://werkzeug.pocoo.org/"
-arch="noarch"
-license="MIT"
-depends=""
-makedepends="python2-dev python3-dev py-setuptools"
-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
-}
-
-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="64976cc46c1cee2203112c50aba6f9404d4e48d4a90f8b11837148b5415a28572b7e706095586045a46879e853fc5a80c63e7bf0c13eda29d564a37b4a554c0b  Werkzeug-0.14.1.tar.gz"
diff --git a/main/py3-werkzeug/APKBUILD b/main/py3-werkzeug/APKBUILD
new file mode 100644
index 0000000000..820173f32a
--- /dev/null
+++ b/main/py3-werkzeug/APKBUILD
@@ -0,0 +1,31 @@ 
+# Contributor:
+# Maintainer: prspkt <prspkt@protonmail.com>
+pkgname=py3-werkzeug
+_pyname=Werkzeug
+pkgver=0.15.4
+pkgrel=0
+pkgdesc="The WSGI swiss-army knife"
+url="http://werkzeug.pocoo.org/"
+arch="noarch"
+license="MIT"
+makedepends="python3-dev py3-setuptools"
+checkdepends="py3-pytest"
+_pypiprefix="${_pyname%${_pyname#?}}"
+source="https://files.pythonhosted.org/packages/source/$_pypiprefix/$_pyname/$_pyname-$pkgver.tar.gz"
+builddir="$srcdir/$_pyname-$pkgver"
+replaces="py-werkzeug"
+provides="py-werkzeug=$pkgver-r$pkgrel"
+
+build() {
+	python3 setup.py build
+}
+
+check() {
+	PYTHONPATH="$builddir"/src pytest-3
+}
+
+package() {
+	python3 setup.py install --prefix=/usr --root="$pkgdir"
+}
+
+sha512sums="b27b313cb29128ad1a1d0b04be7d1b29eacd4fb8280757510ce662b4f8743e7311966f7fb170531bd5dcb9668e9c6672f0cc0cf53bb4af3ec7328312a88b53ab  Werkzeug-0.15.4.tar.gz"