diff options
author | Francesco Colista <fcolista@alpinelinux.org> | 2017-08-25 09:26:34 +0000 |
---|---|---|
committer | Francesco Colista <fcolista@alpinelinux.org> | 2017-08-25 09:26:34 +0000 |
commit | b75bc83b379490fd61b289d355a9a9d455ec9a60 (patch) | |
tree | 0737c1bfbefc02efd5455fdc980192cd15efaf30 /testing/py-redmine | |
parent | ffcd5b1c592746d7cb20e3cde87a7de281a1468e (diff) | |
download | aports-b75bc83b379490fd61b289d355a9a9d455ec9a60.tar.bz2 aports-b75bc83b379490fd61b289d355a9a9d455ec9a60.tar.xz |
testing/py-redmine: upgrade to 2.0.2, added check(), added py2/py3 subpackages
Diffstat (limited to 'testing/py-redmine')
-rw-r--r-- | testing/py-redmine/APKBUILD | 53 |
1 files changed, 31 insertions, 22 deletions
diff --git a/testing/py-redmine/APKBUILD b/testing/py-redmine/APKBUILD index b96fa0f523..659c12c27e 100644 --- a/testing/py-redmine/APKBUILD +++ b/testing/py-redmine/APKBUILD @@ -2,40 +2,49 @@ # Maintainer: Fabian Affolter <fabian@affolter-engineering.ch> pkgname=py-redmine _pkgname=python-redmine -pkgver=0.9.0 +pkgver=2.0.2 pkgrel=0 pkgdesc="A simple library for communicating with redmine" url="https://github.com/maxtepkeev/python-redmine" arch="noarch" license="ASL 2.0" depends="python2 py-requests" -depends_dev="" -makedepends="python2-dev py-setuptools" -install="" -subpackages="" +makedepends="python2-dev python3-dev py-setuptools" +subpackages="py3-${pkgname/py-/}:_py3 py2-${pkgname/py-/}:_py2" 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" - for i in $source; do - case $i in - *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; - esac - done +build() { + cd "$builddir" + python2 setup.py build + python3 setup.py build } -build() { - cd "$_builddir" - python2 setup.py build || return 1 +check() { + cd "$builddir" + python2 setup.py check + python3 setup.py check } package() { - cd "$_builddir" - python2 setup.py install --prefix=/usr --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" +} + +_py3() { + _py python3 } -md5sums="0eff9a334d25f807b6b87a552f75d9d2 python-redmine-0.9.0.tar.gz" -sha256sums="cd6e11c9a95f661ecda9e81e64d53c9a67e09fe9c5168c206fe596936829ac82 python-redmine-0.9.0.tar.gz" -sha512sums="be92e1671c7893bf997de10b7ee8f86d91c24e3fcef1a1e3fe9db2d41391039a26e38cac7e8a2e3554b574fb9d8205d29c22dd1682a8202cf3af4a7d8203873e python-redmine-0.9.0.tar.gz" +sha512sums="3f8e11315e8e2b4474e8b981bd801ef75857fe73e8ed18d27f64223703d18ea2061416ed38ea35c4a4460a4ccba167b41ab48e2489930181951e9e2a5f53ec12 python-redmine-2.0.2.tar.gz" |