-
Notifications
You must be signed in to change notification settings - Fork 19
/
PKGBUILD
31 lines (28 loc) · 1.23 KB
/
PKGBUILD
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# Maintainer: Antheas Kapenekakis <aur at antheas dot dev>
pkgname=hhd
pkgver=VERSION
pkgrel=1
pkgdesc='Handheld Daemon. A tool for managing the quirks of handheld devices.'
arch=('x86_64')
url='https://github.com/hhd-dev/hhd'
license=('GPL-3.0-or-later' 'MIT')
depends=('python' 'python-setuptools' 'python-evdev' 'python-rich' 'python-yaml' 'python-xlib' 'libusb' 'python-pyserial' 'lsof')
optdepends=('hhd-user: allows running hhd as a user service.')
makedepends=('python-'{'build','installer','setuptools','wheel'})
source=("https://pypi.python.org/packages/source/h/hhd/hhd-${pkgver}.tar.gz")
sha512sums=('SKIP')
build() {
cd "hhd-$pkgver"
python -m build --wheel --no-isolation
}
package() {
cd "hhd-$pkgver"
python -m installer --destdir="$pkgdir" dist/*.whl
# Install minimally necessary rules for running as a system service
mkdir -p ${pkgdir}/usr/lib/udev/rules.d/
install -m644 usr/lib/udev/rules.d/83-hhd.rules ${pkgdir}/usr/lib/udev/rules.d/83-hhd.rules
mkdir -p ${pkgdir}/usr/lib/udev/hwdb.d/
install -m644 usr/lib/udev/hwdb.d/83-hhd.hwdb ${pkgdir}/usr/lib/udev/hwdb.d/83-hhd.hwdb
mkdir -p ${pkgdir}/usr/lib/systemd/system/
install -m644 usr/lib/systemd/system/[email protected] ${pkgdir}/usr/lib/systemd/system/[email protected]
}