From 3e8da06c1faeb7884689a8af959cd9fa5bdf4e4f Mon Sep 17 00:00:00 2001 From: Ross Burton Date: Thu, 21 Feb 2013 16:41:33 +0000 Subject: systemd: split out the hwdb data The hardware databases are not essential and also quite large, so split them out into udev-hwdb. Signed-off-by: Ross Burton --- meta/recipes-core/systemd/systemd_197.bb | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) (limited to 'meta/recipes-core') diff --git a/meta/recipes-core/systemd/systemd_197.bb b/meta/recipes-core/systemd/systemd_197.bb index 56ced66b01..a006ec8e92 100644 --- a/meta/recipes-core/systemd/systemd_197.bb +++ b/meta/recipes-core/systemd/systemd_197.bb @@ -180,13 +180,13 @@ RRECOMMENDS_${PN} += "systemd-serialgetty \ kernel-module-autofs4 kernel-module-unix kernel-module-ipv6 \ " -PACKAGES =+ "udev-dbg udev udev-consolekit udev-utils" +PACKAGES =+ "udev-dbg udev udev-consolekit udev-utils udev-hwdb" FILES_udev-dbg += "/lib/udev/.debug" RDEPENDS_udev += "udev-utils" RPROVIDES_udev = "hotplug" -RRECOMMENDS_udev += "udev-extraconf" +RRECOMMENDS_udev += "udev-extraconf udev-hwdb" FILES_udev += "${base_sbindir}/udevd \ ${base_libdir}/systemd/systemd-udevd \ @@ -209,7 +209,6 @@ FILES_udev += "${base_sbindir}/udevd \ /lib/udev/rules.d/78*.rules \ /lib/udev/rules.d/8*.rules \ /lib/udev/rules.d/95*.rules \ - ${base_libdir}/udev/hwdb.d \ ${sysconfdir}/udev \ ${systemd_unitdir}/system/*udev* \ ${systemd_unitdir}/system/*.wants/*udev* \ @@ -220,6 +219,8 @@ RDEPENDS_udev-consolekit += "${@base_contains('DISTRO_FEATURES', 'x11', 'console FILES_udev-utils = "${bindir}/udevadm" +FILES_udev-hwdb = "${base_libdir}/udev/hwdb.d" + # TODO: # u-a for runlevel and telinit @@ -239,6 +240,21 @@ update-alternatives --remove shutdown ${base_bindir}/systemctl update-alternatives --remove poweroff ${base_bindir}/systemctl } +pkg_postinst_udev-hwdb () { + if test -n "$D"; then + exit 1 + fi + + udevadm hwdb --update +} + +pkg_prerm_udev-hwdb () { + if test -n "$D"; then + exit 1 + fi + + rm -f ${sysconfdir}/udev/hwdb.bin +} # As this recipe builds udev, respect the systemd DISTRO_FEATURE so we don't try # building udev and systemd in world builds. -- cgit v1.2.3