summaryrefslogtreecommitdiff
path: root/user
diff options
context:
space:
mode:
Diffstat (limited to 'user')
-rw-r--r--user/hwdata/APKBUILD47
-rw-r--r--user/hwdata/install-T.patch11
-rw-r--r--user/hwids/APKBUILD70
3 files changed, 70 insertions, 58 deletions
diff --git a/user/hwdata/APKBUILD b/user/hwdata/APKBUILD
deleted file mode 100644
index a25f9b891..000000000
--- a/user/hwdata/APKBUILD
+++ /dev/null
@@ -1,47 +0,0 @@
-# Maintainer:
-pkgname=hwdata
-pkgver=0.316
-pkgrel=0
-pkgdesc="Hardware identification and configuration data"
-url="https://github.com/vcrhonek/hwdata"
-arch="noarch"
-options="!check" # requires pciutils, which causes build loop
-license="GPL-2.0+"
-subpackages="$pkgname-usb $pkgname-pci $pkgname-pnp $pkgname-oui"
-depends="$subpackages"
-makedepends="bash"
-source="$pkgname-$pkgver.tar.gz::https://github.com/vcrhonek/hwdata/archive/v$pkgver.tar.gz
- install-T.patch"
-
-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="8d43b91e6c410c43d6831f793a8e5a71903072ebc72cfd3414fa70fb76efaa873474bfbdd6af015970c3e43f7ba65eaa4e0a781f87ad1170be82afc793ef6d3c hwdata-0.316.tar.gz
-88a786d8feb5c8b7de587ac70f3e4307d10ac5ed9b0edfc8711de1ba51808ca33a76df518cb5a508215c309289a079a778a91c3e6fc359d644d230de8d23f049 install-T.patch"
diff --git a/user/hwdata/install-T.patch b/user/hwdata/install-T.patch
deleted file mode 100644
index a98400841..000000000
--- a/user/hwdata/install-T.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- ./Makefile.orig 2014-04-22 06:38:35.320410230 +0000
-+++ ./Makefile 2014-04-22 06:39:15.260889885 +0000
-@@ -33,7 +33,7 @@
- install -m 644 $$foo $(DESTDIR)$(datadir)/$(NAME) ;\
- done
- mkdir -p -m 755 $(DESTDIR)$(libdir)/modprobe.d
-- install -m 644 -T blacklist.conf $(DESTDIR)$(libdir)/modprobe.d/dist-blacklist.conf
-+ install -m 644 blacklist.conf $(DESTDIR)$(libdir)/modprobe.d/dist-blacklist.conf
-
- commit:
- git commit -a ||:
diff --git a/user/hwids/APKBUILD b/user/hwids/APKBUILD
new file mode 100644
index 000000000..92d161907
--- /dev/null
+++ b/user/hwids/APKBUILD
@@ -0,0 +1,70 @@
+# Contributor: A. Wilcox <awilfox@adelielinux.org>
+# Maintainer: A. Wilcox <awilfox@adelielinux.org>
+pkgname=hwids
+pkgver=20180917
+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+"
+makedepends="eudev-dev"
+subpackages="$pkgname-net $pkgname-pci $pkgname-udev $pkgname-usb"
+depends="$subpackages"
+subpackages="$subpackages $pkgname-doc"
+source="https://github.com/gentoo/hwids/archive/hwids-$pkgver.tar.gz"
+builddir="$srcdir/hwids-hwids-$pkgver"
+
+build() {
+ cd "$builddir"
+ make UDEV=yes
+}
+
+package() {
+ cd "$builddir"
+ 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="9fdcd5a7b3adca1bed886aa83e9cf3944391a819fc9f09b673bd815d95e6e70cecf40d8e87287207e34bfeb58c888188fc61b1c0ac13c1ecab0efbdb5100f8d9 hwids-20180917.tar.gz"