blob: 17760d3c641a7fa364f09432c3256d4ea044fde7 (
plain) (
tree)
|
|
# Contributor: A. Wilcox <awilfox@adelielinux.org>
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=hwids
pkgver=20200204
pkgrel=0
pkgdesc="Hardware identification databases"
url="https://github.com/gentoo/hwids/"
arch="noarch"
options="!check" # No test suite, just databases.
license="BSD-3-Clause OR GPL-2.0+"
subpackages="$pkgname-net $pkgname-pci $pkgname-udev $pkgname-usb"
depends="$subpackages"
makedepends="eudev-dev"
subpackages="$subpackages $pkgname-doc"
source="https://github.com/gentoo/hwids/archive/hwids-$pkgver.tar.gz"
builddir="$srcdir/hwids-hwids-$pkgver"
build() {
make UDEV=yes
}
package() {
make DESTDIR="$pkgdir" DOCDIR="/usr/share/doc/$pkgname-$pkgver" \
MISCDIR="/usr/share/hwdata" UDEV=yes install
}
_mv() {
local _file
pkgdesc="$pkgdesc ($1)"
shift
depends=""
mkdir -p "$subpkgdir"/usr/share/hwdata
for _file in $*; do
mv "$pkgdir"/usr/share/hwdata/$_file "$subpkgdir"/usr/share/hwdata
done
}
usb() {
replaces="hwdata-usb"
provides="hwdata-usb=$pkgver-r$pkgrel"
_mv "USB IDs" usb.ids
}
pci() {
replaces="hwdata-pci"
provides="hwdata-pci=$pkgver-r$pkgrel"
_mv "PCI IDs" pci.ids
}
net() {
replaces="hwdata-oui"
provides="hwdata-oui=$pkgver-r$pkgrel"
license="Public-Domain"
_mv "Networking OUIs" oui.txt iab.txt
}
udev() {
install_if="hwids=$pkgver-r$pkgrel eudev"
install_if="hwids-pci=$pkgver-r$pkgrel eudev"
install_if="hwids-usb=$pkgver-r$pkgrel eudev"
pkgdesc="$pkgdesc (udev integration)"
mkdir -p "$subpkgdir"/
mv "$pkgdir"/lib "$subpkgdir"/
mv "$pkgdir"/etc "$subpkgdir"/
}
sha512sums="1d2a9baaa7ab64575a3d9b98ae4df9060cb8593ae752365296dd53b18bc5996170bbfe1c5b4b1ffc24b28e3dbaa7c321c4fa333bbf91449a6ca7b187cbe23741 hwids-20200204.tar.gz"
|