aboutsummaryrefslogtreecommitdiffstats
path: root/main/hwdata/APKBUILD
blob: a69de884c08f5ba8b6abaa37017a6060553cc8ef (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
44
45
46
47
48
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=hwdata
pkgver=0.302
pkgrel=0
pkgdesc="Hardware identification and configuration data"
url="https://github.com/vcrhonek/hwdata"
arch="noarch"
license="GPL2+"
makedepends="bash"
subpackages="$pkgname-usb $pkgname-pci $pkgname-pnp $pkgname-oui"
depends="$subpackages"
source="$pkgname-$pkgver.tar.gz::https://github.com/vcrhonek/hwdata/archive/v$pkgver.tar.gz
	install-T.patch"

builddir="$srcdir"/hwdata-$pkgver

build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--datadir=/usr/share
	# nothing to make
}

package() {
	cd "$builddir"
	make -j1 DESTDIR="$pkgdir" install
	# remove modprobe blacklist
	rm -r "$pkgdir"/usr/lib
}

_mv() {
	pkgdesc="$pkgdesc - $1"
	depends=""
	mkdir -p "$subpkgdir"/usr/share/hwdata
	mv "$pkgdir"/usr/share/hwdata/$1 "$subpkgdir"/usr/share/hwdata
}

usb() { replaces="usbutils"; _mv usb.ids; }
pci() { replaces="pciutils"; _mv pci.ids; }
pnp() { _mv pnp.ids; }
oui() { _mv oui.txt; }

sha512sums="95149b7cb8db1bd82550eb16cc517b9698034f90ea62cda8f40cd5c331efe475e9be2a2606e17d144d843e9ffcf4d0e99d31e68c61eec098722ad43e709ce16f  hwdata-0.302.tar.gz
88a786d8feb5c8b7de587ac70f3e4307d10ac5ed9b0edfc8711de1ba51808ca33a76df518cb5a508215c309289a079a778a91c3e6fc359d644d230de8d23f049  install-T.patch"