aboutsummaryrefslogtreecommitdiffstats
path: root/testing/py-cherrypy/APKBUILD
diff options
context:
space:
mode:
authorFabian Affolter <fabian@affolter-engineering.ch>2016-11-08 22:00:00 +0000
committerTimo Teräs <timo.teras@iki.fi>2016-12-27 09:49:51 +0200
commit3ed6b015e4afbcf9ffa8d4d4ff04ebb7f1db9a1a (patch)
treec95a61847b5d466043a247a7f82806672256a8d1 /testing/py-cherrypy/APKBUILD
parentcc221f4962b8c9aedd584c84889149d5868bbd67 (diff)
downloadaports-3ed6b015e4afbcf9ffa8d4d4ff04ebb7f1db9a1a.tar.bz2
aports-3ed6b015e4afbcf9ffa8d4d4ff04ebb7f1db9a1a.tar.xz
testing/py-cherrypy: upgrade to 8.1.2 and enable py3
Diffstat (limited to 'testing/py-cherrypy/APKBUILD')
-rw-r--r--testing/py-cherrypy/APKBUILD49
1 files changed, 34 insertions, 15 deletions
diff --git a/testing/py-cherrypy/APKBUILD b/testing/py-cherrypy/APKBUILD
index ce8a3616c0..3481dc2a93 100644
--- a/testing/py-cherrypy/APKBUILD
+++ b/testing/py-cherrypy/APKBUILD
@@ -1,31 +1,50 @@
# Contributor: Francesco Colista <francesco.colista@gmail.com>
-# Maintainer:
+# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch>
pkgname=py-cherrypy
_pkgname=CherryPy
-pkgver=3.2.4
+pkgver=8.1.2
pkgrel=0
pkgdesc="A pythonic, object-oriented web development framework"
url="http://www.cherrypy.org"
arch="noarch"
license="BSD"
-depends="python2"
-depends_dev="python2-dev"
-makedepends="$depends_dev"
-install=""
-subpackages=""
+depends="py-six"
+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
-_builddir="$srcdir"/$_pkgname-$pkgver
build() {
- cd "$_builddir"
+ cd "$builddir"
python2 setup.py build || return 1
+ python3 setup.py build || return 1
}
package() {
- cd "$_builddir"
- python2 setup.py install --root=$pkgdir
- install -Dm644 cherrypy/LICENSE.txt ${pkgdir}/usr/share/licenses/custom/${pkgname}/license
+ mkdir -p "$pkgdir"
}
-md5sums="e2c8455e15c39c9d60e0393c264a4d16 CherryPy-3.2.4.tar.gz"
-sha256sums="abd73a449936740e99d3a05eb89b9381dc188ef696904f585463bc28079f1288 CherryPy-3.2.4.tar.gz"
-sha512sums="f559630ba23b88edb1c9085cd0b916c816d2f6b51fde17ad3c617bf2da49f37874d603bab2b3763e9329ca283fc6a08b68a76911f40901ed09d3f6222b95e033 CherryPy-3.2.4.tar.gz"
+
+_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"
+}
+
+md5sums="553f054152c2adbe60738682ed5390c5 CherryPy-8.1.2.tar.gz"
+sha256sums="45a92fdd18baa19d055e5f53bb3c4293821a30e83bf3c5244b867685397f5380 CherryPy-8.1.2.tar.gz"
+sha512sums="63c267969df2d24e46f63685773b2af55595f8a162f8abd91e4b2877fedc4b42ec67c8a2c79d4c0f999cbaa1fd3fff7df103914af6f105e08f6e1d256dd390f5 CherryPy-8.1.2.tar.gz"