[maemo-developers] Fremantle Community SSU

From: Andrew Flegg andrew at bleb.org
Date: Tue Nov 2 10:37:53 EET 2010
On Tue, Nov 2, 2010 at 08:32, Marius Vollmer <marius.vollmer at nokia.com> wrote:
> ext Niels Breet <niels at maemo.org> writes:
>
>> Problem Mohammad faced here is that HAM holds a lock, so you can't run
>> apt-get in the background. This is why he needs to open the xterm and
>> ask the user to close HAM.
>
> Yes.  But what about launching that script from a launcher entry instead
> of asking people to type something into an xterm?  I think that inspires
> a bit more confidence.

The way it's supposed to work (worked for X-Fade, but not me) is that
the X Terminal opens running a script which says "Please close HAM and
press enter; any remaining dpkg-lock holding processes will be
killed".

TBH, I wonder whether that's really necessary - presumably it's
possible via D-Bus to open HAM in "check for upgrade mode" (i.e. what
the notifier status menu applet does). What if the postinst starts a
nohup task which:

  1) sleeps for some period of time (say, 5-10 seconds)
  2) asks HAM to quit (simulating a close button press or just killall)
  3) restarts HAM in "check for upgrades" mode.

The user would have fewer interactions (clicking the "Update all"
button in HAM, once restarted) and it'd be more seamless and,
according to my gut, less prone to error.

Thoughts?

Cheers,

Andrew

-- 
Andrew Flegg -- mailto:andrew at bleb.org  |  http://www.bleb.org/
Maemo Community Council member
More information about the maemo-developers mailing list