! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
"Broken" migration to xfce4-panel 4.7
Status:
RESOLVED: FIXED
Product:
Xfce4-notes-plugin
Component:
General

Comments

Description Lionel Le Folgoc 2010-12-14 22:48:06 CET
Hi,

When built against xfce4-panel 4.6, xfce4-notes-plugin (1.7.[67]) ships xfce4-notes-plugin.desktop.
But when built against xfce4-panel 4.7, the filename is different: xfce4-notes-plugin-47.desktop.

This seems to prevent a smooth migration from xfce4-panel 4.6 to 4.7, as the panel cannot find the plugin anymore (because of the name change). Notes are not lost (when adding again the plugin they are still here), but this is frightening for "normal" users, and not easily understandable…

Is it possible to ship a desktop file with the same name in both cases, in order to provide clean upgrades?

Thanks!
Comment 1 Lionel Le Folgoc 2010-12-14 22:58:25 CET
For example, with xfce4-panel 4.6, in ~/.config/xfce4/panel/panels.xml, there is:

<item name="xfce4-notes-plugin" id="12781557350"/>

But when using xfce4-panel 4.7.x, the name changed (in ~/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-panel.xml):

<property name="plugin-5" type="string" value="xfce4-notes-plugin-47"/>

(I'm not sure the .desktop filename is used to generate the plugin name, but it seems very likely.)
Comment 2 Mike Massonnet editbugs 2010-12-15 09:27:47 CET
I can't go back to look at how things were done and why, but there sure was a reason.

> Is it possible to ship a desktop file with the same name in both cases, in
> order to provide clean upgrades?

No, the difference inside the desktop file entries is beneath:

--- xfce4-notes-plugin.desktop.in.in	2009-12-23 13:11:07.000000000 +0100
+++ xfce4-notes-plugin-47.desktop.in	2009-12-23 13:11:07.000000000 +0100
@@ -4,5 +4,6 @@
 _Name=Notes
 _Comment=Ideal for your quick notes
 Icon=xfce4-notes-plugin
-X-XFCE-Exec=@EXTERNAL_PLUGIN_PATH@/xfce4-notes-plugin
 X-XFCE-Unique=true
+X-XFCE-Module=notes
+X-XFCE-Internal=FALSE

One uses the Exec key, the other the Module key.

Well, I'll keep the bug open, as there should be a possibility to tweak the Makefile in order to generate a unique xfce4-notes-plugin.desktop for both cases.
Comment 3 Lionel Le Folgoc 2010-12-15 19:55:02 CET
(In reply to comment #2)
> I can't go back to look at how things were done and why, but there sure was a
> reason.

If there was one, it is not given in the original commit <http://git.xfce.org/panel-plugins/xfce4-notes-plugin/commit/?id=c2952ae3cabcb336f5bbe565a3431cf11545011b>.

> 
> One uses the Exec key, the other the Module key.
> 

I know that; that's why I was asking for a single filename rather than a single desktop file.

> Well, I'll keep the bug open, as there should be a possibility to tweak the
> Makefile in order to generate a unique xfce4-notes-plugin.desktop for both
> cases.

Thanks.

(there is probably an ugly way by renaming the installed desktop file in an install-data-hook rule)
Comment 4 Mike Massonnet editbugs 2010-12-15 19:58:20 CET
(In reply to comment #3)
> (there is probably an ugly way by renaming the installed desktop file in an
> install-data-hook rule)

You call it ;)
Comment 5 Mike Massonnet editbugs 2011-02-20 22:28:49 CET
git 8c6d36

install-data-hook does the trick
Comment 6 Lionel Le Folgoc 2011-02-22 11:10:05 CET
Thanks for the fix, but there's still a small issue. The hook ignores the DESTDIR, so will likely fail when building a debian package (it will try to change directly /usr/share/blabla instead of the one from the package building directory):

mv $(desktopdir)/xfce4-notes-plugin-47.desktop $(desktopdir)/xfce4-notes-plugin.desktop

should be:

mv $(DESTDIR)/$(desktopdir)/xfce4-notes-plugin-47.desktop $(DESTDIR)/$(desktopdir)/xfce4-notes-plugin.desktop

Thanks!
Comment 7 Mike Massonnet editbugs 2011-02-22 21:56:19 CET
Fine, I wasn't sure about DESTDIR. Thanks for correcting the commit :)
Comment 8 Mike Massonnet editbugs 2012-10-25 01:33:34 CEST
mmh, well, mmh.

now that's not the best way to end this issue, but the next version won't provide a panel plugin valid for xfce <= 4.6.

sorry.

changes apply in following git commit:
http://git.xfce.org/panel-plugins/xfce4-notes-plugin/commit/?id=d11fe51fae95b5b4963847be76ae4a07409a6076

Bug #6993

Reported by:
Lionel Le Folgoc
Reported on: 2010-12-14
Last modified on: 2012-10-25

People

Assignee:
Mike Massonnet
CC List:
0 users

Version

Version:
unspecified

Attachments

Additional information