diff options
author | Leo <thinkabit.ukim@gmail.com> | 2019-07-20 15:23:08 -0300 |
---|---|---|
committer | Leo <thinkabit.ukim@gmail.com> | 2019-07-20 15:23:08 -0300 |
commit | 1513b283111a57348d5da89808589e5a80a0dfa9 (patch) | |
tree | 7d0e62642e6a594469c4636eafcd36ad1e9a62c2 /testing/py3-django-rest-framework | |
parent | d976ab3a9c5c1e4c84c5169f6fff533dae8e8f0e (diff) | |
download | aports-1513b283111a57348d5da89808589e5a80a0dfa9.tar.bz2 aports-1513b283111a57348d5da89808589e5a80a0dfa9.tar.xz |
testing/py3-django-rest-framework: switch to py3
Diffstat (limited to 'testing/py3-django-rest-framework')
-rw-r--r-- | testing/py3-django-rest-framework/APKBUILD | 50 |
1 files changed, 12 insertions, 38 deletions
diff --git a/testing/py3-django-rest-framework/APKBUILD b/testing/py3-django-rest-framework/APKBUILD index 15f6197f2d..e518458026 100644 --- a/testing/py3-django-rest-framework/APKBUILD +++ b/testing/py3-django-rest-framework/APKBUILD @@ -1,56 +1,30 @@ # Contributor: Leonardo Arena <rnalrd@alpinelinux.org> # Maintainer: -pkgname=py-django-rest-framework +pkgname=py3-django-rest-framework +_pkgname=django-rest-framework pkgver=3.8.2 -pkgrel=1 +pkgrel=2 pkgdesc="Web APIs for Django" +options="!check" # fails with "OperationalError: no such table: auth_user" url="https://github.com/encode/django-rest-framework" arch="noarch" license="Custom" -depends="py-django" -makedepends="python2-dev python3-dev py2-setuptools" -checkdepends="pytest py-tz py-core-api py-jinja2 py-uritemplate" -subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" -options="!check" # fails with "OperationalError: no such table: tests_blog" -source="$pkgname-$pkgver.tar.gz::https://github.com/encode/django-rest-framework/archive/$pkgver.tar.gz" -builddir="$srcdir"/django-rest-framework-$pkgver +depends="py3-django" +makedepends="py3-setuptools" +checkdepends="py3-pytest py3-tz py3-core-api py3-jinja2 py3-uritemplate" +source="$pkgname-$pkgver.tar.gz::https://github.com/encode/$_pkgname/archive/$pkgver.tar.gz" +builddir="$srcdir"/$_pkgname-$pkgver build() { - cd "$builddir" - python2 setup.py --quiet build python3 setup.py --quiet build } -package() { - cd "$builddir" - mkdir -p "$pkgdir"/usr/bin -} - check() { - cd "$builddir" - python2 runtests.py python3 runtests.py } -_py2() { - depends="${depends//py-/py2-}" - _py python2 -} - -_py3() { - depends="${depends//py-/py3-}" - _py python3 -} - -_py() { - local python="$1" - local pyver="${1:6:1}" - pkgdesc="$pkgdesc (for $python)" - depends="$depends $python" - install_if="$pkgname=$pkgver-r$pkgrel $python" - - cd "$builddir" - $python setup.py --quiet install --prefix=/usr --root="$subpkgdir" +package() { + python3 setup.py --quiet install --prefix=/usr --root="$pkgdir" } -sha512sums="603c86a4741a37a22a2be273136eb4d1eaa0a07aa24ba97b67f9f8d4e7fa254fe9ca7d1fdd44ee9237e86ef4cfe6bdbc8f48954a92f91873c9ef0761813a43d2 py-django-rest-framework-3.8.2.tar.gz" +sha512sums="603c86a4741a37a22a2be273136eb4d1eaa0a07aa24ba97b67f9f8d4e7fa254fe9ca7d1fdd44ee9237e86ef4cfe6bdbc8f48954a92f91873c9ef0761813a43d2 py3-django-rest-framework-3.8.2.tar.gz" |