Quoting Phil Blundell <[email protected]>:

That's testing for offline installation. If $D is not set, it's running on the target.

p.

  one last query before i head off for dinner ... so what about
pkg_postinst() routines that do double duty, like this one from
dbus_1.12.20.bb:


PACKAGE_WRITE_DEPS += "${@bb.utils.contains('DISTRO_FEATURES','systemd sysvinit','systemd-systemctl-native','',d)}"
pkg_postinst:dbus() {
# If both systemd and sysvinit are enabled, mask the dbus-1 init script if ${@bb.utils.contains('DISTRO_FEATURES','systemd sysvinit','true','false',d)}; then
                if [ -n "$D" ]; then
                        OPTS="--root=$D"
                fi
                systemctl $OPTS mask dbus-1.service
        fi

        if [ -z "$D" ] && [ -e /etc/init.d/populate-volatile.sh ] ; then
                /etc/init.d/populate-volatile.sh update
        fi
}


note how that routine checks its context and, as i recall (but
it's not documented in the docs i'm looking at), i'd swear that
i read somewhere that if a pkg_postinst() routine fails at image
creation time, it was deferred until boot time, which would
explain the above routine checking its runtime context.

  anyway, off for food.

rday

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#155329): 
https://lists.openembedded.org/g/openembedded-core/message/155329
Mute This Topic: https://lists.openembedded.org/mt/85146007/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to