diff options
author | David Runge | 2022-08-01 07:22:40 +0000 |
---|---|---|
committer | David Runge | 2022-08-01 07:22:40 +0000 |
commit | 0bdb6bea56e98bd218a8d436b965afeb95ed6907 (patch) | |
tree | 6174a6439ed61c646d398dcaa15d1024529ca666 | |
download | aur-0bdb6bea56e98bd218a8d436b965afeb95ed6907.tar.gz |
Add python-pc-ble-driver-py as dependency for python-nrfutil (new dependency for python-pynitrokey).
-rw-r--r-- | PKGBUILD | 41 | ||||
-rw-r--r-- | python-pc-ble-driver-py-0.17.0-build_deps.patch | 10 |
2 files changed, 51 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..c46ca3181c28 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,41 @@ +# Maintainer: David Runge <dvzrv@archlinux.org> + +_name=pc-ble-driver-py +pkgname=python-pc-ble-driver-py +pkgver=0.17.0 +pkgrel=1 +pkgdesc="Serialization library over serial port providing bindings for nrf-ble-driver" +arch=(x86_64) +url="https://github.com/NordicSemiconductor/pc-ble-driver-py" +license=(custom) +depends=(gcc-libs glibc pc-ble-driver python-cryptography python-wrapt) +makedepends=(cmake ninja python-build python-installer python-scikit-build python-setuptools python-wheel swig) +# no sdist tarballs on pypi.org: https://github.com/NordicSemiconductor/pc-ble-driver-py/issues/185 +# source=(https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz) +source=( + $_name-$pkgver.tar.gz::https://github.com/NordicSemiconductor/pc-ble-driver-py/archive/refs/tags/v$pkgver.tar.gz + $pkgname-0.17.0-build_deps.patch +) +sha256sums=('1e9ef5c1d994bc12aef0c5a325beb6845cb31a9c70c0bcb0e2639c19b6e689f5' + 'dddbdeaffeb7c4c3cbc399199157b108965f19b29c985ae4ef0f262a95865ad9') +b2sums=('923503b0b1eebe9e39c74bb1b0a0ef9a070f6f25f51d7728df844a5c7bd9a23f454da08b7f4873f364b914e1052ccfeed3488464d8b7a05145c7a0a959c9346f' + 'caa70040fd664546b53e7ad481b41d1e910c4cfdb00f5e9f89306c0ba6ad9823d8e520adc9a04bc607c01c316940600bb4f3444bd50c5a5e87f312895f688050') + +prepare() { + # we do not need tox, cmake or ninja as build tools + patch -Np1 -d $_name-$pkgver -i ../$pkgname-0.17.0-build_deps.patch +} + +build() { + cd $_name-$pkgver + python -m build --wheel --no-isolation +} + +# NOTE: tests can not be run: https://github.com/NordicSemiconductor/pc-ble-driver-py/issues/225 + +package() { + cd $_name-$pkgver + python -m installer --destdir="$pkgdir" dist/*.whl + install -vDm 644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname/" + install -vDm 644 README.md -t "$pkgdir/usr/share/doc/$pkgname/" +} diff --git a/python-pc-ble-driver-py-0.17.0-build_deps.patch b/python-pc-ble-driver-py-0.17.0-build_deps.patch new file mode 100644 index 000000000000..cfc5087f6817 --- /dev/null +++ b/python-pc-ble-driver-py-0.17.0-build_deps.patch @@ -0,0 +1,10 @@ +diff -ruN a/pyproject.toml b/pyproject.toml +--- a/pyproject.toml 2022-07-06 15:36:11.000000000 +0200 ++++ b/pyproject.toml 2022-07-31 22:43:21.367424662 +0200 +@@ -1,5 +1,5 @@ + [build-system] +-requires = ["setuptools", "wheel", "scikit-build", "cmake", "ninja", "tox"] ++requires = ["setuptools", "wheel", "scikit-build"] + + [flake8] + exclude = [ |