]> code.ossystems Code Review - openembedded-core.git/commit
systemd: Reinstate systemd-hwdb-update.service
authorAlex Kiernan <alex.kiernan@gmail.com>
Fri, 27 Mar 2020 17:25:11 +0000 (17:25 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 30 Mar 2020 11:33:24 +0000 (12:33 +0100)
commit78ff610e571e4d739326520c391a37ee1f1290ae
tree53936f8549a0bd5b20981201ea0e6719d53517e0
parentf9081994db3872af993d21db259a628cd834973f
systemd: Reinstate systemd-hwdb-update.service

systemd supports a distribution hwdb.bin in /usr/lib/udev/hwdb.bin,
which is used if /etc/udev/hwdb.bin is not present. When generating the
install time hwdb, for systemd, ensure that we put it in /usr/lib/udev,
which then ensures that at boot time we do not regenerate it, unless the
system is marked for update.

This allows fragments dropped into /etc/udev/hwdb.d to be processed
correctly, but without requiring a first boot time build:

root@qemumips:~# systemctl status systemd-hwdb-update.service
* systemd-hwdb-update.service - Rebuild Hardware Database
     Loaded: loaded (/usr/lib/systemd/system/systemd-hwdb-update.service; static; vendor preset: disabled)
     Active: inactive (dead)
  Condition: start condition failed at Wed 2020-03-04 15:18:11 UTC; 44s ago
             |- ConditionPathExists=|!/usr/lib/udev/hwdb.bin was not met
             |- ConditionPathExists=|/etc/udev/hwdb.bin was not met
             `- ConditionDirectoryNotEmpty=|/etc/udev/hwdb.d was not met
       Docs: man:hwdb(7)
             man:systemd-hwdb(8)

Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
Acked-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-core/systemd/systemd_244.3.bb
scripts/postinst-intercepts/update_udev_hwdb