[OE-core] [PATCH] rootfs_ipk: respect ONLINE_PACKAGE_MANAGEMENT

Phil Blundell pb at pbcl.net
Thu May 19 10:31:08 UTC 2011


On Thu, 2011-05-19 at 11:15 +0100, Richard Purdie wrote:
> We have postinstalls that require to run on the target device. If
> they're present, we need opkg there to run them, or at least some kind
> of script to handle that and I think both cases have a requirement on
> that directory (the rpm backend has a suitable script).
> 
> So the current patches which just don't create it don't really address
> the problem. At the very least the image generation should error if
> these types of postinstall are present which I guess is my real concern.

Ah, I see what you mean now.  Yes, it is true that packages which expect
to get their postinst run on the target will lose in this case.  But,
practically speaking, this is not likely to be too much of a limitation:
devices which have O_P_M=none tend to be the same ones that have their
root filesystem on readonly media, so running postinsts on the target is
likely to be futile anyway.  (Also, O_P_M=none targets will generally
not install opkg in their rootfs in any case.)

I agree it would be a good thing for the build to emit an error in this
case rather than just causing the postinsts to silently not run.  I
guess the ideal way of dealing with this would be:

a) introduce a new variable, TARGET_FILESYSTEM_READONLY or some such,
and make it an error for there to be any packages left in "install ok
unpacked" at the end of rootfs construction if this flag is set;

b) for the case where O_P_M="none" but T_F_R is not set, provide an
additional postprocessor to distill the opkg status file down to just
the bits that are needed for postinst running, and also provide some
lightweight script to run the postinsts and then clean up afterwards.

p.






More information about the Openembedded-core mailing list