summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: ab592941a6bf7dc9fc4465bc3eda2b54ec390e02 (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
# Maintainer: MiguVT <cuentas@miguvt.com>

pkgname=fixvr-git
pkgver=r1.e85e0d9
pkgrel=1
pkgdesc="udev rule that fixes the Valve Index blank EDID (640×480) bug on Linux"
arch=('any')
url="https://github.com/MiguVT/fixvr"
license=('MIT')
makedepends=('git')
optdepends=('xr-hardware: udev access rules for Valve hidraw/USB nodes (avoids duplicate rules)'
            'steam-devices: steam-devices provides the same Valve access rules')
provides=('fixvr')
conflicts=('fixvr')
install=fixvr.install
source=("$pkgname::git+https://github.com/MiguVT/fixvr.git")
b2sums=('SKIP')

pkgver() {
	cd "$pkgname"
	printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

package() {
	cd "$pkgname"

	# udev rule — installed under /usr/lib so pacman owns it cleanly;
	# /etc/udev/rules.d/ is reserved for local admin overrides.
	install -Dm644 src/99-valve-index-reboot.rules \
		"$pkgdir/usr/lib/udev/rules.d/99-valve-index-reboot.rules"

	install -Dm644 LICENSE \
		"$pkgdir/usr/share/licenses/$pkgname/LICENSE"

	# Install the upstream README as documentation.
	install -Dm644 README.md \
		"$pkgdir/usr/share/doc/$pkgname/README.md"
}