summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/udev
diff options
context:
space:
mode:
authorKai Kang <kai.kang@windriver.com>2018-10-18 04:18:05 -0400
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-10-22 07:05:13 +0100
commitd6b737a31a8842cdc770b05e28503c81a691d10d (patch)
treeda211c858bd6f5b5dc239be1667dd74a2b7dae47 /meta/recipes-core/udev
parentdaba6c5a991b370709d17e51305334f55a3858ec (diff)
downloadopenembedded-core-contrib-d6b737a31a8842cdc770b05e28503c81a691d10d.tar.gz
openembedded-core-contrib-d6b737a31a8842cdc770b05e28503c81a691d10d.tar.bz2
openembedded-core-contrib-d6b737a31a8842cdc770b05e28503c81a691d10d.zip
udev-hwdb: fix postinstall scripts failures when multilib enabled
When multilib is enabled and both udev-hwdb and ${MLPREFIX}udev-hwdb are installed to image, it fails to run one of their postinstall scripts that they both call ${base_bindir}/udevadm with same user mode qemu. Duplicate udevadm and add postinst-intercept update_udev_hwdb to fix the failures. Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/udev')
-rw-r--r--meta/recipes-core/udev/eudev_3.2.5.bb11
1 files changed, 5 insertions, 6 deletions
diff --git a/meta/recipes-core/udev/eudev_3.2.5.bb b/meta/recipes-core/udev/eudev_3.2.5.bb
index efd62c6495..592dd8f22a 100644
--- a/meta/recipes-core/udev/eudev_3.2.5.bb
+++ b/meta/recipes-core/udev/eudev_3.2.5.bb
@@ -50,6 +50,10 @@ do_install_append() {
# hid2hci has moved to bluez4. removed in udev as of version 169
rm -f ${D}${base_libdir}/udev/hid2hci
+
+ # duplicate udevadm for postinst script
+ install -d ${D}${libexecdir}
+ ln ${D}${bindir}/udevadm ${D}${libexecdir}/${MLPREFIX}udevadm
}
do_install_prepend_class-target () {
@@ -81,12 +85,7 @@ RPROVIDES_eudev-hwdb += "udev-hwdb"
PACKAGE_WRITE_DEPS += "qemu-native"
pkg_postinst_eudev-hwdb () {
if test -n "$D"; then
- if ${@bb.utils.contains('MACHINE_FEATURES', 'qemu-usermode', 'true','false', d)}; then
- ${@qemu_run_binary(d, '$D', '${bindir}/udevadm')} hwdb --update --root $D
- chown root:root $D${sysconfdir}/udev/hwdb.bin
- else
- $INTERCEPT_DIR/postinst_intercept delay_to_first_boot ${PKG} mlprefix=${MLPREFIX}
- fi
+ $INTERCEPT_DIR/postinst_intercept update_udev_hwdb ${PKG} mlprefix=${MLPREFIX} binprefix=${MLPREFIX}
else
udevadm hwdb --update
fi