On 09/25/2013 12:03 PM, Richard Purdie wrote:
On Tue, 2013-09-24 at 16:30 +0200, David Nyström wrote:
I'm have a question about this though.
diff --git a/meta/recipes-extended/shadow/shadow.inc
b/meta/recipes-extended/shadow/shadow.inc
index 4df5e5e..75b0afc 100644
--- a/meta/recipes-extended/shadow/shadow.inc
+++ b/meta/recipes-extended/shadow/shadow.inc
<snip>
+pkg_postinst_${PN} () {
+ if [ "x$D" != "x" ]; then
+ rootarg="--root=$D"
+ else
+ rootarg=""
+ fi
+
+ pwconv $rootarg
+ grpconv $rootarg
+}
<snip>
This will introduce the postinstall hook for both ${BPN}-native and
${BPN} ?. Before the change, the postinstall hook was activated only by
${BPN} afaict. Tried removing it from native* through
pkg_postinst_${BPN}, but that does not seem to work.
Basically the postinst is ignored for the -native version. It never gets
packaged so isn't relevant. Adding in special cases for native for each
and every recipe would get ugly very quickly.
Sorry, bad wording on my end. I was worried about nativesdk
post/prefuncs beeing added.
<snip>
Also, seems like ${sysconfdir} in the nativesdk-opkg postinstall expands to:
chmod 0755 $D${sysconfdir}/rcS.d/S${POSTINSTALL_INITPOSITION}run-postinsts
chmod 0755
$D/opt/poky/1.4+snapshot/sysroots/x86_64-pokysdk-linux/etc/rcS.d/S98run-postinsts
Is this really expected behaviour ?
nativesdk postinstalls are probably badly handled at the moment.
I Agree, it would be good with a consistent handling between nativesdk
and target pre/postinstall hooks.
I'll try to dive into this subject when I have more time.
I suspect if things can run at rootfs creation time they work out, if they
can't run then, they never happen at all. We don't have a "first boot"
of the sdk...
Cheers,
Richard
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core