[oe] opkg: How to make package signal reboot required?

Bryan Evenson bevenson at melinkcorp.com
Thu Aug 1 12:27:32 UTC 2013


Martin and Paul,

Thanks for the replies.  If there is nothing standard in place at the moment, then I'm planning on setting things up on my end to follow the standard (from what I can tell) Debian practice.  In my pkg_postinst, I'm going to add the lines:

#!/bin/sh -e
if test "x$D" = "x"; then
    touch /var/run/reboot-required
    cat ${PN} >> /var/run/reboot-required.pkgs
fi

Then in my script that does the firmware upgrade, I'll check for the existence of /var/run/reboot-required to determine whether the system needs to be rebooted.

If anything can be done to add the above (or something similar) to the pkg_postinst by setting a flag in the Bitbake recipe, I'm all for it.  I'm not quite sure which piece would be responsible for such action (oe-core?  Bitbake? Something else?).  If someone could suggest the proper place, I'd happily submit a request on the proper bug tracker.

Regards,
Bryan

> -----Original Message-----
> From: openembedded-devel-bounces at lists.openembedded.org
> [mailto:openembedded-devel-bounces at lists.openembedded.org] On Behalf Of
> Martin Jansa
> Sent: Thursday, August 01, 2013 6:33 AM
> To: openembedded-devel at lists.openembedded.org
> Subject: Re: [oe] opkg: How to make package signal reboot required?
> 
> On Wed, Jul 31, 2013 at 09:28:50PM -0400, Bryan Evenson wrote:
> > All,
> >
> > I have a package that I created for my setup which, when upgraded,
> will require a system reboot.  Is there a general flag/setting that
> already exists to put in my Bitbake recipe to signal that the package
> requires a reboot?  If so, does it just set a flag that a reboot is
> required or does it force a reboot?
> 
> I don't know about the feature to do the reboot, but we were using
> extra metadata flags for .ipk to mark packages which need the reboot
> (so that package manager can query updated packages and decide if it's
> needed).
> 
> See
> http://patches.openembedded.org/patch/39181/
> http://patches.openembedded.org/patch/39183/
> 
> I don't know why this wasn't ever merged in oe-core
> http://lists.linuxtogo.org/pipermail/openembedded-core/2012-
> November/031856.html
> doesn't have any negative review AFAIK.
> 
> --
> Martin 'JaMa' Jansa     jabber: Martin.Jansa at gmail.com



More information about the Openembedded-devel mailing list