summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 03f442f9576dd5d601a0cc9d8826d4de9afd78a3 (plain)
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
32
33
34
35
36
37
38
39
40
41
42
43
# Maintainer: Pietro Carrara <pbcarrara@inf.ufrgs.br>

pkgname=digimend-drivers-git-dkms
pkgver=10.r0.gec5c16d
pkgrel=1
pkgdesc='Linux kernel modules (DKMS) for non-Wacom USB graphics tablets. Git version.'
arch=('any')
url='https://digimend.github.io'
license=('GPL2')
depends=('dkms')
optdepends=('xf86-input-wacom: for xorg wacom driver support')
makedepends=('git')
conflicts=(digimend-kernel-drivers digimend-kernel-drivers-dkms)
provides=(digimend-kernel-drivers)

source=('git+https://github.com/DIGImend/digimend-kernel-drivers.git')

md5sums=('SKIP')

pkgver() {
    cd digimend-kernel-drivers
    git describe --long | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}

package() {
    cd digimend-kernel-drivers

    # Udev rules
    install -D -m 0755 hid-rebind "$pkgdir"/etc/udev/rules.d/hid-rebind
    install -D -m 0644 udev.rules "$pkgdir"/etc/udev/rules.d/90-digimend.rules

    # Use wacom drivers with supported tablets
    install -D -m 0644 xorg.conf "$pkgdir"/usr/share/X11/xorg.conf.d/50-digimend.conf

    # DKMS config
    install -Dm644 dkms.conf "$pkgdir"/usr/src/digimend-${pkgver}/dkms.conf

    # Depmod config
    install -D -m 0644 depmod.conf "$pkgdir"/etc/depmod.d/digimend.conf

    # Add source files to the DKMS tree
    cp -r ./* "$pkgdir/usr/src/digimend-$pkgver"
}