Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.gentoo.dev > #70483
| From | Lukas Schmelting <lschmelting@posteo.com> |
|---|---|
| Newsgroups | linux.gentoo.dev |
| Subject | [gentoo-dev] Re: [PATCH 2/3] udev.eclass: add udev_hwdb_update function |
| Date | 2026-04-29 21:40 +0200 |
| Message-ID | <MPiVj-1lOD-3@gated-at.bofh.it> (permalink) |
| References | <MOVvI-166w-11@gated-at.bofh.it> <MPhmx-1kDL-3@gated-at.bofh.it> <MPhmx-1kDL-9@gated-at.bofh.it> <MPhZg-1l8v-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
[Multipart message — attachments visible in raw view] - view raw
On Mi, Apr 29, 2026 at 02:32 Mike Gilbert <floppym@gentoo.org> wrote:
> On Wed, Apr 29, 2026 at 1:51 PM Lukas Schmelting <lschmelting@posteo.com> wrote:
>>
>> update the udev hardware database binary using the `systemd-hwdb update`
>> command. The `udevadm hwdb` has been deprecated upstream.
>>
>> See-also: https://github.com/systemd/systemd/commit/f8717d2a723cf594617c3acb7e90992c881a3280
>> Signed-off-by: Lukas Schmelting <lschmelting@posteo.com>
>> ---
>> eclass/udev.eclass | 16 ++++++++++++++++
>> 1 file changed, 16 insertions(+)
>>
>> diff --git a/eclass/udev.eclass b/eclass/udev.eclass
>> index 7d1c213fa643..afdf7c91c7a9 100644
>> --- a/eclass/udev.eclass
>> +++ b/eclass/udev.eclass
>> @@ -130,3 +130,19 @@ udev_reload() {
>> }
>>
>> fi
>> +
>> +# @FUNCTION: udev_hwdb_update
>> +# @DESCRIPTION:
>> +
>> +# Rebuild the systemd hwdb binary database used by udev for hardware
>> +# property lookups. Should be called from pkg_postinst and pkg_postrm
>> +# in packages installing hwdb files.
>> +udev_hwdb_update() {
>> + if [[ -n ${ROOT} ]]; then
>> + return 0
>> + fi
>> +
>> + ebegin "Running systemd-hwdb update to regenerate binary udev hardware database"
>> + systemd-hwdb update --root "${ROOT}"
>> + eend $?
>> +}
>> --
>> 2.53.0
>
> I pushed the udev.eclass patch along with a follow-up fix.
Thanks!
--
Best regards
Lukas Schmelting (eluks)
Back to linux.gentoo.dev | Previous | Next — Previous in thread | Next in thread | Find similar
[gentoo-dev] [PATCH 0/3] refactor and extend udev handling Lukas Schmelting <lschmelting@posteo.com> - 2026-04-28 20:20 +0200
[gentoo-dev] [PATCH 2/3] udev.eclass: add udev_hwdb_reload function Lukas Schmelting <lschmelting@posteo.com> - 2026-04-28 20:30 +0200
[gentoo-dev] Re: [PATCH 2/3] udev.eclass: add udev_hwdb_reload function Mike Gilbert <floppym@gentoo.org> - 2026-04-28 20:40 +0200
[gentoo-dev] [PATCH v2 0/2] range-diff v1/v2 Lukas Schmelting <lschmelting@posteo.com> - 2026-04-29 00:10 +0200
[gentoo-dev] [PATCH v2 3/3] metadata/install-qa-check.d: add udev hwdb check Lukas Schmelting <lschmelting@posteo.com> - 2026-04-29 00:20 +0200
[gentoo-dev] [PATCH v2 2/3] udev.eclass: add udev_hwdb_update function Lukas Schmelting <lschmelting@posteo.com> - 2026-04-29 00:20 +0200
[gentoo-dev] [PATCH 3/3] metadata/install-qa-check.d: add udev hwdb check Lukas Schmelting <lschmelting@posteo.com> - 2026-04-29 20:00 +0200
[gentoo-dev] [PATCH 0/3] "bash -n" fixes and nits Lukas Schmelting <lschmelting@posteo.com> - 2026-04-29 20:00 +0200
[gentoo-dev] [PATCH 1/3] metadata/install-qa-check.d: refactor 60udev-eclass Lukas Schmelting <lschmelting@posteo.com> - 2026-04-29 20:00 +0200
[gentoo-dev] [PATCH 2/3] udev.eclass: add udev_hwdb_update function Lukas Schmelting <lschmelting@posteo.com> - 2026-04-29 20:00 +0200
[gentoo-dev] Re: [PATCH 2/3] udev.eclass: add udev_hwdb_update function Mike Gilbert <floppym@gentoo.org> - 2026-04-29 20:40 +0200
[gentoo-dev] Re: [PATCH 2/3] udev.eclass: add udev_hwdb_update function Lukas Schmelting <lschmelting@posteo.com> - 2026-04-29 21:40 +0200
[gentoo-dev] [PATCH 1/3] metadata/install-qa-check.d: refactor 60udev-eclass Lukas Schmelting <lschmelting@posteo.com> - 2026-04-28 20:30 +0200
[gentoo-dev] [PATCH 3/3] metadata/install-qa-check.d: add udev hwdb check Lukas Schmelting <lschmelting@posteo.com> - 2026-04-28 20:30 +0200
csiph-web