aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Hamann <michael@content-space.de>2018-04-06 22:27:35 +0200
committerRoberto Oliveira <robertoguimaraes8@gmail.com>2018-07-04 08:55:39 +0000
commit575ab8fa82a4f46267030111a26192e3f409ebbb (patch)
tree6f3991fc502dd7002fb1827cff0bef9e9f25ef66
parent1f7880fd173c1f926aff4cbf51801aafd4cdca13 (diff)
downloadaports-575ab8fa82a4f46267030111a26192e3f409ebbb.tar.bz2
community/py-distutils-extra: Add python3 support
-rw-r--r--community/py-distutils-extra/APKBUILD34
1 files changed, 31 insertions, 3 deletions
diff --git a/community/py-distutils-extra/APKBUILD b/community/py-distutils-extra/APKBUILD
index 59efe7a..91c39fb 100644
--- a/community/py-distutils-extra/APKBUILD
+++ b/community/py-distutils-extra/APKBUILD
@@ -3,24 +3,52 @@
pkgname=py-distutils-extra
_pkgname=python-distutils-extra
pkgver=2.39
-pkgrel=1
+pkgrel=2
pkgdesc="Enhanced distutils package for python"
url="https://launchpad.net/python-distutils-extra"
arch="noarch"
license="GPL"
depends="py-setuptools"
-makedepends="python2-dev"
+makedepends="python2-dev python3-dev"
+subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3"
source="https://launchpad.net/python-distutils-extra/trunk/$pkgver/+download/$_pkgname-$pkgver.tar.gz"
builddir="$srcdir/$_pkgname-$pkgver"
build() {
cd "$builddir"
python2 setup.py build
+ python3 setup.py build
}
+check() {
+ cd "$builddir"
+ python2 setup.py check
+ python3 setup.py check
+}
+
+
package() {
cd "$builddir"
- python2 setup.py install --root="$pkgdir"
+ 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 --root="$subpkgdir"
}
sha512sums="e3b4d1ed22767fb4c6dbbdccef960865b6fda01d18dc38cb8f9357c09c7eabb78466fce053e407a196eca257d07d57c5c1ef47f358a5979c7f22e4b11775124e python-distutils-extra-2.39.tar.gz"