aboutsummaryrefslogtreecommitdiffstats
path: root/community/py3-sensehat
diff options
context:
space:
mode:
authorLeo <thinkabit.ukim@gmail.com>2019-09-07 16:24:50 -0300
committerLeo <thinkabit.ukim@gmail.com>2019-09-07 16:49:23 -0300
commita28f263424b94b15d5b5f995fb38bc9f28aba59d (patch)
treec876bcca9a0b49919a29e951ea727c5b2f7683af /community/py3-sensehat
parent4e3325449e6b2e8be3890137b8bbe8b68fdc4047 (diff)
downloadaports-a28f263424b94b15d5b5f995fb38bc9f28aba59d.tar.bz2
aports-a28f263424b94b15d5b5f995fb38bc9f28aba59d.tar.xz
community/py3-sensehat: drop py2
Diffstat (limited to 'community/py3-sensehat')
-rw-r--r--community/py3-sensehat/APKBUILD50
1 files changed, 12 insertions, 38 deletions
diff --git a/community/py3-sensehat/APKBUILD b/community/py3-sensehat/APKBUILD
index cd6a13beeb..13991fe7e7 100644
--- a/community/py3-sensehat/APKBUILD
+++ b/community/py3-sensehat/APKBUILD
@@ -1,54 +1,28 @@
# Contributor: ScrumpyJack <scrumpyjack@st.ilet.to>
# Maintainer: ScrumpyJack <scrumpyjack@st.ilet.to>
-pkgname=py-sensehat
+pkgname=py3-sensehat
_pkgname=python-sense-hat
pkgver=2.2.0
-pkgrel=1
-pkgdesc="Python module to control the Raspberry Pi Sense HAT"
+pkgrel=2
+pkgdesc="Python3 module to control the Raspberry Pi Sense HAT"
url="https://www.raspberrypi.org/products/sense-hat/"
arch="armhf armv7"
license="BSD-3-Clause"
-depends=""
-# Package doesn't provide tests
-options="!check"
-makedepends="python2-dev python3-dev py-setuptools"
-subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3"
-source="$_pkgname-$pkgver.tar.gz::https://github.com/RPi-Distro/${_pkgname}/archive/v${pkgver}.tar.gz"
-builddir=${srcdir}/${_pkgname}-${pkgver}
+depends="python3"
+options="!check" # Package doesn't provide tests
+makedepends="py3-setuptools"
+source="$_pkgname-$pkgver.tar.gz::https://github.com/RPi-Distro/$_pkgname/archive/v$pkgver.tar.gz"
+builddir="$srcdir/$_pkgname-$pkgver"
+
+replaces="py-sensehat" # Backwards compatibility
+provides="py-sensehat=$pkgver-r$pkgrel" # Backwards compatibility
build() {
- cd "$builddir"
- python2 setup.py build
python3 setup.py build
}
-#check() {
-# cd "$builddir"
-# python2 setup.py test
-# python3 setup.py test
-#}
-
package() {
- 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 --prefix=/usr --root="$subpkgdir"
+ python3 setup.py install --prefix=/usr --root="$pkgdir"
}
sha512sums="71914f6f22206cff23992a6908698978741a46bf9b98648388bac4550f39e8de73db6bd389b79585eba6e82160649a8c8da4217d515bbdbcb50d47218415f3ac python-sense-hat-2.2.0.tar.gz"