diff options
author | David P <megver83@parabola.nu> | 2019-11-13 16:21:17 -0300 |
---|---|---|
committer | David P <megver83@parabola.nu> | 2019-11-13 16:21:17 -0300 |
commit | e248e462fc0dc8b520ed9c55d2ac37a77b5eaa9a (patch) | |
tree | 4b7ee322f85a89f1a63cefb607cdc22b60ba4bd5 /nonsystemd/eudev | |
parent | d94a8ccae66c35c65aaeba35bec8d585c0758f6f (diff) | |
download | abslibre-e248e462fc0dc8b520ed9c55d2ac37a77b5eaa9a.tar.gz abslibre-e248e462fc0dc8b520ed9c55d2ac37a77b5eaa9a.tar.bz2 abslibre-e248e462fc0dc8b520ed9c55d2ac37a77b5eaa9a.zip |
addpkg: nonsystemd/eudev 3.2.9-1
Signed-off-by: David P <megver83@parabola.nu>
Diffstat (limited to 'nonsystemd/eudev')
-rw-r--r-- | nonsystemd/eudev/30-udev-hwdb.hook | 11 | ||||
-rw-r--r-- | nonsystemd/eudev/30-udev-reload.hook | 11 | ||||
-rw-r--r-- | nonsystemd/eudev/PKGBUILD | 98 | ||||
-rw-r--r-- | nonsystemd/eudev/initcpio_hooks | 20 | ||||
-rw-r--r-- | nonsystemd/eudev/initcpio_install | 27 | ||||
-rw-r--r-- | nonsystemd/eudev/udev-default-rules.patch | 31 | ||||
-rw-r--r-- | nonsystemd/eudev/udev-hook | 16 | ||||
-rw-r--r-- | nonsystemd/eudev/udev-hwdb-path.patch | 24 |
8 files changed, 238 insertions, 0 deletions
diff --git a/nonsystemd/eudev/30-udev-hwdb.hook b/nonsystemd/eudev/30-udev-hwdb.hook new file mode 100644 index 000000000..eb17c9ff2 --- /dev/null +++ b/nonsystemd/eudev/30-udev-hwdb.hook @@ -0,0 +1,11 @@ +[Trigger] +Type = File +Operation = Install +Operation = Upgrade +Operation = Remove +Target = usr/lib/udev/hwdb.d/* + +[Action] +Description = Updating udev Hardware Database... +When = PostTransaction +Exec = /usr/share/libalpm/scripts/udev-hook hwdb diff --git a/nonsystemd/eudev/30-udev-reload.hook b/nonsystemd/eudev/30-udev-reload.hook new file mode 100644 index 000000000..418515daf --- /dev/null +++ b/nonsystemd/eudev/30-udev-reload.hook @@ -0,0 +1,11 @@ +[Trigger] +Type = File +Operation = Install +Operation = Upgrade +Operation = Remove +Target = usr/lib/udev/rules.d/* + +[Action] +Description = Reloading device manager configuration... +When = PostTransaction +Exec = /usr/share/libalpm/scripts/udev-hook udev-reload diff --git a/nonsystemd/eudev/PKGBUILD b/nonsystemd/eudev/PKGBUILD new file mode 100644 index 000000000..dd8d97cea --- /dev/null +++ b/nonsystemd/eudev/PKGBUILD @@ -0,0 +1,98 @@ +# Maintainer: David P. <megver83@parabola.nu> +# Contributor: Luke Shumaker <lukeshu@sbcglobal.net> +# Contributor: Omar Vega Ramos <ovruni@gnu.org.pe> +# Maintainer (Artix): artoo <artoo@artixlinux.org> +# Contributor (Artix): Alexey D. <lq07829icatm@rambler.ru> +# Contributor (Artix): Ivailo Monev <xakepa10@gmail.com> + +_udev_ver=243 + +pkgbase=eudev +pkgname=('eudev' 'eudev-libudev') +pkgver=3.2.9 +pkgrel=1 +pkgdesc="The userspace dev tools (udev) forked by Gentoo" +arch=('x86_64' 'i686' 'armv7h') +url="http://www.gentoo.org/proj/en/eudev/" +license=('GPL') +makedepends=('gobject-introspection' 'gperf' 'gtk-doc' 'intltool' 'kmod' 'util-linux' 'libelf') +options=('!libtool') +source=("$pkgname-$pkgver.tar.gz::https://github.com/gentoo/eudev/archive/v${pkgver}.tar.gz" + 'initcpio_hooks' + 'initcpio_install' + '30-udev-hwdb.hook' + '30-udev-reload.hook' + 'udev-hook' + 'udev-hwdb-path.patch' + 'udev-default-rules.patch') +sha256sums=('7d281276b480da3935d1acb239748c2c9db01a8043aad7e918ce57a223d8cd24' + '892ce43218e0a458981bbce451252c8987dc398e60b8de288e7542b8f2409c13' + '77dd1fd318b4456409aceb077f060b87944defb07cf39d29ad1968dc6f361875' + '2782bd3a7686596e98bd2d3fdef9d59d7d439682b87bbcc43b1fd1f5fabb3505' + '13596caef6ed85b58de674ebe7c47d9c7dd676240de5cc28ef3ccee2ce1d8a90' + '80c8f87549374d3bc7c2831b9e069b0005cc5ef90122c2d02e78e27c9bc1dbed' + 'e05e468d15d09fb49343f33bc8d21c08f54db3ecff412dc35d4acb0630f869a3' + '13c167e448411b53b18532469e783e2e51a4c46ff4cf9c46e0481d6440b53f8d') + +prepare(){ + cd "${pkgbase}-${pkgver}" + patch -Np 1 -i ${srcdir}/udev-hwdb-path.patch + patch -Np 1 -i ${srcdir}/udev-default-rules.patch + ./autogen.sh +} + +build() { + cd "${pkgbase}-${pkgver}" + + ./configure \ + --prefix=/usr \ + --with-rootprefix=/usr \ + --sysconfdir=/etc \ + --libdir=/usr/lib \ + --sbindir=/usr/bin \ + --enable-introspection \ + --enable-kmod \ + --enable-manpages \ + --enable-split-usr + + make +} + +check(){ + cd "${pkgbase}-${pkgver}" + make -k check +} + +package_eudev() { + provides=("udev=${_udev_ver}" ) + depends=("eudev-libudev=$pkgver" 'kbd' 'kmod' 'hwids' 'util-linux') + backup=('etc/udev/udev.conf') + + cd "${pkgbase}-${pkgver}" + + make DESTDIR="${pkgdir}" install + + install -dm755 ${srcdir}/_libeudev + + mv -v ${pkgdir}/usr/lib/libudev*.so* ${srcdir}/_libeudev + + install -Dm644 "${srcdir}/initcpio_hooks" "${pkgdir}/usr/lib/initcpio/hooks/udev" + install -Dm644 "${srcdir}/initcpio_install" "${pkgdir}/usr/lib/initcpio/install/udev" + + # pacman hooks + install -Dm755 ${srcdir}/udev-hook "$pkgdir"/usr/share/libalpm/scripts/udev-hook + install -Dm644 -t "$pkgdir"/usr/share/libalpm/hooks ${srcdir}/*.hook +} + +package_eudev-libudev() { + pkgdesc="eudev client libraries" + depends=('glibc' 'libelf') + provides=("libudev=${_udev_ver}" 'libudev.so') + + provides+=("libeudev=$pkgver") + conflicts+=('libeudev') + replaces+=('libeudev') + + install -dm755 ${pkgdir}/usr/lib + mv -v ${srcdir}/_libeudev/libudev*.so* ${pkgdir}/usr/lib +} diff --git a/nonsystemd/eudev/initcpio_hooks b/nonsystemd/eudev/initcpio_hooks new file mode 100644 index 000000000..75da7e4a8 --- /dev/null +++ b/nonsystemd/eudev/initcpio_hooks @@ -0,0 +1,20 @@ +#!/usr/bin/ash + +run_earlyhook() { + udevd --daemon --resolve-names=never + udevd_running=1 +} + +run_hook() { + msg ":: Triggering uevents..." + udevadm trigger --action=add --type=subsystems + udevadm trigger --action=add --type=devices + udevadm settle +} + +run_cleanuphook() { + udevadm control --exit + udevadm info --cleanup-db +} + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/nonsystemd/eudev/initcpio_install b/nonsystemd/eudev/initcpio_install new file mode 100644 index 000000000..610b71c3d --- /dev/null +++ b/nonsystemd/eudev/initcpio_install @@ -0,0 +1,27 @@ +#!/bin/bash + +build() { + add_file "/etc/udev/udev.conf" + add_binary /usr/bin/udevd + add_binary /usr/bin/udevadm + + for rule in 50-udev-default.rules 60-persistent-storage.rules 64-btrfs.rules 80-drivers.rules; do + add_file "/usr/lib/udev/rules.d/$rule" + done + + for tool in ata_id scsi_id; do + add_file "/usr/lib/udev/$tool" + done + + add_runscript +} + +help() { + cat <<HELPEOF +This hook will use udev to create your root device node and detect the needed +modules for your root device. It is also required for firmware loading in +initramfs. It is recommended to use this hook. +HELPEOF +} + +# vim: set ft=sh ts=4 sw=4 et: diff --git a/nonsystemd/eudev/udev-default-rules.patch b/nonsystemd/eudev/udev-default-rules.patch new file mode 100644 index 000000000..019fac194 --- /dev/null +++ b/nonsystemd/eudev/udev-default-rules.patch @@ -0,0 +1,31 @@ +--- a/rules/50-udev-default.rules 2018-10-26 15:42:39.000000000 +0200 ++++ b/rules/50-udev-default.rules 2019-02-20 19:33:07.196155034 +0100 +@@ -22,7 +22,7 @@ + SUBSYSTEM=="tty", KERNEL=="ttysclp[0-9]*", GROUP="tty", MODE="0620" + SUBSYSTEM=="tty", KERNEL=="3270/tty[0-9]*", GROUP="tty", MODE="0620" + SUBSYSTEM=="vc", KERNEL=="vcs*|vcsa*", GROUP="tty" +-KERNEL=="tty[A-Z]*[0-9]|ttymxc[0-9]*|pppox[0-9]*|ircomm[0-9]*|noz[0-9]*|rfcomm[0-9]*", GROUP="dialout" ++KERNEL=="tty[A-Z]*[0-9]|ttymxc[0-9]*|pppox[0-9]*|ircomm[0-9]*|noz[0-9]*|rfcomm[0-9]*", GROUP="uucp" + + SUBSYSTEM=="mem", KERNEL=="mem|kmem|port", GROUP="kmem", MODE="0640" + +@@ -57,13 +57,13 @@ + SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ENV{ID_USB_INTERFACES}=="*:0701??:*", GROUP="lp" + + SUBSYSTEM=="block", GROUP="disk" +-SUBSYSTEM=="block", KERNEL=="sr[0-9]*", GROUP="cdrom" +-SUBSYSTEM=="scsi_generic", SUBSYSTEMS=="scsi", ATTRS{type}=="4|5", GROUP="cdrom" +-KERNEL=="sch[0-9]*", GROUP="cdrom" +-KERNEL=="pktcdvd[0-9]*", GROUP="cdrom" +-KERNEL=="pktcdvd", GROUP="cdrom" ++SUBSYSTEM=="block", KERNEL=="sr[0-9]*", GROUP="optical" ++SUBSYSTEM=="scsi_generic", SUBSYSTEMS=="scsi", ATTRS{type}=="4|5", GROUP="optical" ++KERNEL=="sch[0-9]*", GROUP="optical" ++KERNEL=="pktcdvd[0-9]*", GROUP="optical" ++KERNEL=="pktcdvd", GROUP="optical" + +-SUBSYSTEM=="scsi_generic|scsi_tape", SUBSYSTEMS=="scsi", ATTRS{type}=="1|8", GROUP="tape" ++SUBSYSTEM=="scsi_generic|scsi_tape", SUBSYSTEMS=="scsi", ATTRS{type}=="1|8", GROUP="storage" + SUBSYSTEM=="scsi_generic", SUBSYSTEMS=="scsi", ATTRS{type}=="0", GROUP="disk" + KERNEL=="qft[0-9]*|nqft[0-9]*|zqft[0-9]*|nzqft[0-9]*|rawqft[0-9]*|nrawqft[0-9]*", GROUP="disk" + KERNEL=="loop-control", GROUP="disk", OPTIONS+="static_node=loop-control" diff --git a/nonsystemd/eudev/udev-hook b/nonsystemd/eudev/udev-hook new file mode 100644 index 000000000..d9c793f45 --- /dev/null +++ b/nonsystemd/eudev/udev-hook @@ -0,0 +1,16 @@ +#!/bin/sh -e + +udevd_live() { + if [ ! -d /run/udev ]; then + echo >&2 " Skipped: Device manager is not running." + exit 0 + fi +} + +case $1 in + hwdb) /usr/bin/udevadm hwdb --update ;; + udev-reload) udevd_live; /usr/bin/udevadm control --reload ;; + *) echo >&2 " Invalid operation '$1'"; exit 1 ;; +esac + +exit 0 diff --git a/nonsystemd/eudev/udev-hwdb-path.patch b/nonsystemd/eudev/udev-hwdb-path.patch new file mode 100644 index 000000000..b72a1b9d8 --- /dev/null +++ b/nonsystemd/eudev/udev-hwdb-path.patch @@ -0,0 +1,24 @@ + configure.ac | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 480d22a4e..da27f15b8 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -173,13 +173,13 @@ AC_SUBST([udevlibexecdir], [${rootlibexecdir}]) + # sysconfdir paths + AC_SUBST([udevconfdir],[${sysconfdir}/udev]) + AC_SUBST([udevconffile],[${udevconfdir}/udev.conf]) +-AC_SUBST([udevhwdbdir],[${udevconfdir}/hwdb.d]) +-AC_SUBST([udevhwdbbin],[${udevconfdir}/hwdb.bin]) + + # udevlibexecdir paths + AC_SUBST([udevkeymapdir],[${udevlibexecdir}/keymaps]) + AC_SUBST([udevkeymapforceredir],[${udevkeymapdir}/force-release]) + AC_SUBST([udevrulesdir],[${udevlibexecdir}/rules.d]) ++AC_SUBST([udevhwdbdir],[${udevlibexecdir}/hwdb.d]) ++AC_SUBST([udevhwdbbin],[${udevlibexecdir}/hwdb.bin]) + + # pkgconfigdir paths + AC_SUBST([pkgconfiglibdir], [${libdir}/pkgconfig]) + |