2023-08-09 17:40:52 +00:00

47 lines
1.1 KiB
Plaintext

# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=py3-libusb1
pkgver=3.0.0
pkgrel=0
pkgdesc="Pure-python wrapper for libusb-1.0"
url="https://github.com/vpelletier/python-libusb1"
arch="noarch"
license="LGPL-2.1-only AND GPL-2.0-only"
depends="
libusb
python3
"
makedepends="
py3-gpep517
py3-installer
py3-setuptools
py3-wheel
"
subpackages="$pkgname-pyc"
source="https://pypi.python.org/packages/source/l/libusb1/libusb1-$pkgver.tar.gz"
builddir="$srcdir/libusb1-$pkgver"
build() {
gpep517 build-wheel \
--wheel-dir .dist \
--output-fd 3 3>&1 >&2
}
check() {
# No need to test packaging
rm usb1/__pyinstaller/test_libusb1_packaging.py
python3 -m venv --clear --without-pip --system-site-packages .testenv
.testenv/bin/python3 -m installer .dist/*.whl
.testenv/bin/python3 -m unittest discover
}
package() {
python3 -m installer -d "$pkgdir" \
.dist/*.whl
}
sha512sums="
3e1726e80a5c60a9081410a0da8603b89a15da37c0e8702b7ef846e58c86529568d6cb6d762bc6a10a8aa6f24f51fd1043f80433e93b6a7434731882e7888da8 libusb1-3.0.0.tar.gz
"