aboutsummaryrefslogtreecommitdiffstats
path: root/testing/py-sphinxcontrib-nwdiag/APKBUILD
diff options
context:
space:
mode:
authorFabian Affolter <fabian@affolter-engineering.ch>2016-11-07 22:13:47 +0000
committerTimo Teräs <timo.teras@iki.fi>2016-12-27 09:50:58 +0200
commitf388ce5f9f0f7d3f9db7a78c96dfd97b806c5767 (patch)
tree4af94d9d980c15444237a127857fbae58f42b492 /testing/py-sphinxcontrib-nwdiag/APKBUILD
parentc8f5becbaa284e5f2eed94d31848ec8d0a856ee4 (diff)
downloadaports-f388ce5f9f0f7d3f9db7a78c96dfd97b806c5767.tar.bz2
aports-f388ce5f9f0f7d3f9db7a78c96dfd97b806c5767.tar.xz
testing/py-sphinxcontrib-nwdiag: upgrade to 0.9.5 and enable py3
Diffstat (limited to 'testing/py-sphinxcontrib-nwdiag/APKBUILD')
-rw-r--r--testing/py-sphinxcontrib-nwdiag/APKBUILD48
1 files changed, 34 insertions, 14 deletions
diff --git a/testing/py-sphinxcontrib-nwdiag/APKBUILD b/testing/py-sphinxcontrib-nwdiag/APKBUILD
index 1e33955e38..e74bf08b53 100644
--- a/testing/py-sphinxcontrib-nwdiag/APKBUILD
+++ b/testing/py-sphinxcontrib-nwdiag/APKBUILD
@@ -2,23 +2,21 @@
# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch>
pkgname=py-sphinxcontrib-nwdiag
_pkgname=sphinxcontrib-nwdiag
-pkgver=0.9.1
+pkgver=0.9.5
pkgrel=0
pkgdesc="Sphinx "nwdiag" extension"
url="https://pypi.python.org/pypi/sphinxcontrib-nwdiag"
arch="noarch"
license="BSD"
-depends="python2 py-sphinx py-nwdiag"
-depends_dev=""
-makedepends="python2-dev py-setuptools"
-install=""
-subpackages=""
+depends="py-sphinx py-nwdiag"
+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
prepare() {
local i
- cd "$_builddir"
+ cd "$builddir"
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
@@ -27,15 +25,37 @@ prepare() {
}
build() {
- cd "$_builddir"
+ cd "$builddir"
python2 setup.py build || return 1
+ python3 setup.py build || return 1
}
package() {
- cd "$_builddir"
- python2 setup.py install --prefix=/usr --root="$pkgdir" || return 1
+ mkdir -p "$pkgdir"
}
-md5sums="f144fbd4965109930d8708be6cfc59ba sphinxcontrib-nwdiag-0.9.1.tar.gz"
-sha256sums="c1517258f8cf9469220493c05de9fac7ac08d363dff72a90f3f906c33315a549 sphinxcontrib-nwdiag-0.9.1.tar.gz"
-sha512sums="d1d08c379c9fbfeddc697f38b5f7bf33a23cf9a01219e37254f562794d40da19e8151e798495cf486dce53c342a517302184c472b6a069cae0ec4f1e76bdeacc sphinxcontrib-nwdiag-0.9.1.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="7b5d2db632f446b56601eed8f2bd2025 sphinxcontrib-nwdiag-0.9.5.tar.gz"
+sha256sums="5b0ce78c1f7ccbbf33ca624574b117fa5334c8c17f98306a1e1b30e79db93491 sphinxcontrib-nwdiag-0.9.5.tar.gz"
+sha512sums="2c570d4614aa362c43b2f0bcb901f6bca18f91451f50c901805f85f61184e1b531ea5ee2a82b5bca24e34f0a71470b9bdb9057dcaa82cc1c11eb41306561c5c1 sphinxcontrib-nwdiag-0.9.5.tar.gz"