Bug 222757

Summary: what to call from gnome-main-menu if zen-updater is not present
Product: [openSUSE] openSUSE 10.2 Reporter: Martin Vidner <mvidner>
Component: GNOMEAssignee: Martin Vidner <mvidner>
Status: RESOLVED FIXED QA Contact: E-mail List <qa-bugs>
Severity: Critical    
Priority: P5 - None CC: aj, jsrain, kkaempf, ro
Version: Beta 2 plus   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: Other Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: package-manager
patch to the compiz package in autobuild
Patch to change the default package management commands
package-manager-0.2

Description Martin Vidner 2006-11-20 20:31:26 UTC
If zen-updater.rpm (containing zen-{installer,remover,updater}) is not present for any reason, gnome-main-menu.rpm should continue to function.

For this, I am creating /usr/bin/package-manager and /usr/share/applications/package-manager.desktop.
Comment 1 Martin Vidner 2006-11-20 20:38:24 UTC
Created attachment 106293 [details]
package-manager

A first shot at the wrapper.
TODO:
- which rpm to put it in?
- write package-manager.desktop to call package-manager --install %F
- implement yast2 --update and yast2 --remove
Comment 2 Dan Winship 2006-11-20 23:29:22 UTC
Created attachment 106326 [details]
patch to the compiz package in autobuild

JP asked me to do update gnome-xgl-settings for this and attach the patch so you could commit it in the morning if this makes it in for RC1.

The updated compiz package is in ~danw/compiz, or just getpac it and apply the attached patch to it.
Comment 3 Ruediger Oertel 2006-11-21 00:07:05 UTC
I can take the script from c#1 into aaa_base.
any vetos ?
Comment 4 Ruediger Oertel 2006-11-21 00:10:20 UTC
but the desktop file is missing here ...
Comment 5 Ruediger Oertel 2006-11-21 00:13:49 UTC
and the script is missing a "then" in line 66
Comment 6 James Krehl 2006-11-21 00:48:32 UTC
Created attachment 106337 [details]
Patch to change the default package management commands

JP also asked me to post my patch that reflects this new wrapper script.  Additionally I built some packages with this patch.  Let me know if there's anything else you need from me.  I can do the submission to autobuild myself tomorrow morning, boston time.  Otherwise I hope you have enough if you need to do it earlier.

The packages are here:

http://w3.suse.de/~jimmyk/gnome-main-menu/v0.6.3-43/

Thanks!
Comment 7 Martin Vidner 2006-11-21 08:33:07 UTC
Duh, yes I did not even run the script yesterday, sorry.

Concerning package-manager.desktop, I simply took zen-installer.desktop from B2+ and changed the command to package-manager %F. The remaining question is what icon to use. Currently it uses zen-icon which is under /opt/gnome/share/icons/Tango (tango-icon-theme.rpm) or in /usr/share/pixmaps/zen-icon.png in zen-updater.rpm itself.
Is there a suitable icon in a generic package that I can use? Or should I just copy zen-icon.png to package-manager-icon.png and put it to the same package as package-manager.desktop?
Comment 8 Martin Vidner 2006-11-21 08:46:18 UTC
Created attachment 106351 [details]
package-manager-0.2

Fixed and tested package-manager.
Comment 9 Martin Vidner 2006-11-21 10:09:17 UTC
The yast part:
--update is implemented using --install, which works if there is an update for the package but needlessly reinstalls it if it is up to date :-(
I do not see a quick way to fix this.

--remove works except for a "WTF?!" bug: if the package to be removed has other packages depending on it AND there are updates for them, they are updated instead of removed.
I do not see a quick way to fix this either.
Comment 10 Martin Vidner 2006-11-21 10:48:57 UTC
(In reply to comment #9)
> --update is implemented using --install, which works if there is an update for
> the package but needlessly reinstalls it if it is up to date :-(

I am testing a fix for that that compares the version strings obtained by Pkg::ResolvableProperties.

Status summary:
- Which icon for package-manager.desktop, AJ?
- Where to put package-manager.desktop?
- yast2.rpm-2.14.14 is submitted.
- I will submit yast2-packager-2.14.8, with the --remove bug. (after lunch)
- package-manager script is ready (xsu is a bit dumb but works in usual cases)
- gnome-main-menu submission?
Comment 12 Martin Vidner 2006-11-21 14:25:59 UTC
yast2-packager-2.14.8 submitted.
I will file bugs for comment 9 in hope that the remove thing is easy to fix or work around.
Comment 13 Martin Vidner 2006-11-21 14:51:09 UTC
Talked to Stano.
I will finish the bug off by myself:

- copy /usr/share/pixmaps/zen-icon.png to /usr/share/pixmaps/package-manager-icon.png and put it to libzypp.rpm together with /usr/bin/package-manager (to have it in a common package that does not require a total rebuild like aaa_base.rpm)

- submit Jim's patch from comment 6.
Comment 14 Martin Vidner 2006-11-21 16:03:54 UTC
- I forgot about package-manager.desktop: included in libzypp too.
- dropped Recommends: zen-updater from gnome-main-menu (per AJ's mail from Nov 20, 15:24 CET)
Comment 15 Martin Vidner 2006-11-21 16:15:41 UTC
Tested and submitted libzypp-2.8.5 and gnome-main-menu.

Level completed, player one.
Comment 16 Martin Vidner 2006-11-21 16:40:22 UTC
Comment 2: ~danw/compiz submitted too. Thanks everyone!