aboutsummaryrefslogtreecommitdiffstats
path: root/main/hwdata/APKBUILD
blob: 0162132f4527ffab2f3c3810c0e68a7fbe0a2cd9 (plain) (blame)
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=hwdata
pkgver=0.263
pkgrel=0
pkgdesc="Hardware identification and configuration data"
url="http://git.fedorahosted.org/git/hwdata.git"
arch="noarch"
license="GPL2+"
makedepends="bash"
install=""
subpackages="$pkgname-usb $pkgname-pci $pkgname-pnp $pkgname-oui"
depends="$subpackages"
source="http://fedorahosted.org/releases/h/w/hwdata/hwdata-$pkgver.tar.bz2
	install-T.patch"

_builddir="$srcdir"/hwdata-$pkgver
prepare() {
	local i
	cd "$_builddir"
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

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

package() {
	cd "$_builddir"
	make -j1 DESTDIR="$pkgdir" install || return 1
	# 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; }

md5sums="760371bf1fd65c7e2660c8f693a8bf5e  hwdata-0.263.tar.bz2
14378caaaad45f700cbd78feb3244232  install-T.patch"
sha256sums="98b79781b7c3c72b9161e457408db714b5f12a4ae26ef2cb9dc2486ab83a141d  hwdata-0.263.tar.bz2
003160c58024a4d299561c6a9ae199ce91ae375643a74d0aee3893e42669dc17  install-T.patch"
sha512sums="7b5dc81cf1b23942af5ed7df20990cf239049584ab5c090a6686c55b60d7a4e578cc96a03a8f61f9d2f39076ab11e1710979858eb50383a4064b7e2b43962ca1  hwdata-0.263.tar.bz2
88a786d8feb5c8b7de587ac70f3e4307d10ac5ed9b0edfc8711de1ba51808ca33a76df518cb5a508215c309289a079a778a91c3e6fc359d644d230de8d23f049  install-T.patch"