linuxOS_PX30_CAR/yocto/poky/scripts/postinst-intercepts/update_udev_hwdb
2026-01-20 14:00:13 +08:00

23 lines
438 B
Bash

#!/bin/sh
#
# SPDX-License-Identifier: MIT
#
set -e
case "${PREFERRED_PROVIDER_udev}" in
systemd)
UDEV_EXTRA_ARGS="--usr"
UDEVLIBDIR="${rootlibexecdir}"
;;
*)
UDEV_EXTRA_ARGS=""
UDEVLIBDIR="${sysconfdir}"
;;
esac
rm -f $D${UDEVLIBDIR}/udev/hwdb.bin
PSEUDO_UNLOAD=1 ${binprefix}qemuwrapper -L $D $D${libexecdir}/${binprefix}udevadm hwdb --update --root $D ${UDEV_EXTRA_ARGS}
chown root:root $D${UDEVLIBDIR}/udev/hwdb.bin