aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeo <thinkabit.ukim@gmail.com>2021-01-24 19:12:06 -0300
committerLeo <thinkabit.ukim@gmail.com>2021-01-24 19:12:06 -0300
commitf40f8160c9b69db2b2e116673278a24b6a3d143a (patch)
tree9d1af477e65d90f911b573ee6ef5a806d1d7c21f
parentcf7653740ff72b11b2d8007647c1189b9c2f90b3 (diff)
downloadaports-f40f8160c9b69db2b2e116673278a24b6a3d143a.tar.gz
aports-f40f8160c9b69db2b2e116673278a24b6a3d143a.tar.bz2
aports-f40f8160c9b69db2b2e116673278a24b6a3d143a.tar.xz
community/py3-usb: don't use scm version, use our pkgver
-rw-r--r--community/py3-usb/APKBUILD16
1 files changed, 13 insertions, 3 deletions
diff --git a/community/py3-usb/APKBUILD b/community/py3-usb/APKBUILD
index d7db408641..7999dd90cf 100644
--- a/community/py3-usb/APKBUILD
+++ b/community/py3-usb/APKBUILD
@@ -2,19 +2,29 @@
pkgname=py3-usb
_pkgname=pyusb
pkgver=1.1.1
-pkgrel=0
+pkgrel=1
pkgdesc="easy USB devices communication in Python3"
url="https://github.com/pyusb/pyusb"
arch="noarch"
license="BSD-3-Clause"
depends="python3"
-makedepends="py3-setuptools py3-setuptools_scm"
-source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
+makedepends="py3-setuptools"
+source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz
+ "
builddir="$srcdir"/$_pkgname-$pkgver
replaces="py-usb" # Backwards compatibility
provides="py-usb=$pkgver-r$pkgrel" # Backwards compatibility
+prepare() {
+ default_prepare
+
+ sed -e 's|^setup_requires =.*||g' -i setup.cfg
+ sed -e '/setup_requires=setuptools_scm/d' \
+ -e "s/use_scm_version=.*,/version=\"$pkgver\",/" \
+ -i setup.py
+}
+
build() {
python3 setup.py build
}