GNOME Bugzilla – Bug 586527
Get rid of deprecated libgnome(ui)
Last modified: 2009-08-07 15:42:43 UTC
According to http://www.gnome.org/~fpeters/299.html g-c-c depends on libgnomeui. Libgnomeui must die for GNOME3. See http://live.gnome.org/LibgnomeMustDie . Some of the results here may be false positives (if I remember correctly gnome-desktop-thumbnail.h is just a namespace pollution), however using this as a tracking bug for g-c-c. ./shell/control-center.c:#include <libgnomeui/libgnomeui.h> ./shell/control-center.c:#include <libgnome/gnome-desktop-item.h> ./libwindow-settings/gnome-window-manager.h:#include <libgnome/gnome-desktop-item.h> ./capplets/common/gnome-theme-test.c:#include <libgnome/gnome-desktop-item.h> ./capplets/common/gnome-theme-info.c:#include <libgnome/gnome-desktop-item.h> ./capplets/appearance/gnome-wp-item.h:#include <libgnomeui/gnome-bg.h> ./capplets/appearance/appearance-desktop.c:#include <libgnomeui/gnome-bg.h> ./capplets/display/xrandr-capplet.c:#include <libgnomeui/gnome-rr.h> ./capplets/display/xrandr-capplet.c:#include <libgnomeui/gnome-rr-config.h> ./capplets/display/xrandr-capplet.c:#include <libgnomeui/gnome-rr-labeler.h> ./capplets/appearance/appearance-themes.c:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/gnome-wp-item.h:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/appearance-desktop.c:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/appearance.h:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/gnome-wp-info.h:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/about-me/gnome-about-me.c:#include <libgnomeui/gnome-desktop-thumbnail.h> ./libwindow-settings/gnome-window-settings-2.0.pc.in:Requires: gtk+-2.0 libgnomeui-2.0 ./configure.in:PKG_CHECK_MODULES(LIBSLAB, $COMMON_MODULES libgnomeui-2.0 gnome-desktop-2.0 librsvg-2.0 libgnome-menu pango libgnomeui-2.0) ./configure.in:PKG_CHECK_MODULES(GNOMECC_SHELL, $COMMON_MODULES libgnomeui-2.0 libgnome-menu libpanelapplet-2.0) ./configure.in:PKG_CHECK_MODULES(FONT_VIEWER, $COMMON_MODULES $xft_modules libgnomeui-2.0)
Please ignore the "libgnomeui/gnome-desktop-thumbnail.h" part - that's from gnome-desktop and not libgnomeui.
So, the current status after inclusion of libslab and a fresh grep: ================ Code to port: ================ ./libslab/libslab-utils.h:#include <libgnomeui/gnome-thumbnail.h> Functionality is now provided by gnome-desktop. Should be trivial. See any of the <libgnomeui/gnome-desktop-thumbnail.h> port examples already existing in g-c-c. ./libslab/document-tile.c:#include <libgnomeui/gnome-icon-lookup.h> One match that should be trivial to fix: icon_id = gnome_icon_lookup ( gtk_icon_theme_get_default (), thumbnail_factory, TILE (tile)->uri, NULL, NULL, priv->mime_type, 0, NULL); ./shell/control-center.c:#include <libgnomeui/libgnomeui.h> This generic header should be <libgnomeui/gnome-ui-init.h> instead as this seems to be only about using gnome_ui_init() once. ./libslab/app-shell.c:#include <libgnomeui/libgnomeui.h> This generic header should be <libgnomeui/gnome-app.h> instead. ================ Unused includes: ================ ./libslab/libslab-utils.c:#include <libgnome/gnome-url.h> ./libslab/slab-gnome-util.c:#include <libgnome/gnome-url.h> Both usages were fixed in libslab before it was imported: http://bugzilla.gnome.org/show_bug.cgi?id=570725 The headers should be removed. ./libslab/directory-tile.c:#include <libgnomeui/gnome-icon-lookup.h> This is unused and can be removed. ./libslab/system-tile.c:#include <libgnomeui/gnome-client.h> This is unused and can be removed. ================ Nothing to do: ================ ./capplets/appearance/appearance-themes.c:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/gnome-wp-item.h:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/appearance-desktop.c:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/appearance.h:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/gnome-wp-info.h:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/about-me/gnome-about-me.c:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/display/xrandr-capplet.c:#include <libgnomeui/gnome-rr.h> ./capplets/display/xrandr-capplet.c:#include <libgnomeui/gnome-rr-config.h> ./capplets/display/xrandr-capplet.c:#include <libgnomeui/gnome-rr-labeler.h> ./capplets/appearance/gnome-wp-item.h:#include <libgnomeui/gnome-bg.h> ./capplets/appearance/appearance-desktop.c:#include <libgnomeui/gnome-bg.h> ./libslab/app-resizer.c:#include <libgnome/gnome-desktop-item.h> ./libslab/app-shell.c:#include <libgnome/gnome-desktop-item.h> ./libslab/gnome-utils.h:#include <libgnome/gnome-desktop-item.h> ./libslab/shell-window.h:#include <libgnome/gnome-desktop-item.h> ./libslab/application-tile.h:#include <libgnome/gnome-desktop-item.h> ./libslab/slab-gnome-util.h:#include <libgnome/gnome-desktop-item.h> ./libslab/system-tile.h:#include <libgnome/gnome-desktop-item.h> ./libslab/app-shell-startup.c:#include <libgnome/gnome-desktop-item.h> ./libslab/libslab-utils.h:#include <libgnome/gnome-desktop-item.h> ./libwindow-settings/gnome-window-manager.h:#include <libgnome/gnome-desktop-item.h> ./shell/control-center.c:#include <libgnome/gnome-desktop-item.h> ./0001-Clean-up-generic-include-by-using-an-explicit-one.patch: #include <libgnome/gnome-desktop-item.h> ./capplets/common/gnome-theme-test.c:#include <libgnome/gnome-desktop-item.h> ./capplets/common/gnome-theme-info.c:#include <libgnome/gnome-desktop-item.h> ./capplets/appearance/appearance-themes.c:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/gnome-wp-item.h:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/appearance-desktop.c:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/appearance.h:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/appearance/gnome-wp-info.h:#include <libgnomeui/gnome-desktop-thumbnail.h> ./capplets/about-me/gnome-about-me.c:#include <libgnomeui/gnome-desktop-thumbnail.h> All these are part of gnome-desktop. Namespace pollutions; not an issue.
Created attachment 138702 [details] [review] Remove unused #include's
Patch committed to master: 0435304d98044c2343a59d49f3f0b5d2c1d45553
(In reply to comment #2) > > ================ > Code to port: > ================ > > ./libslab/libslab-utils.h:#include <libgnomeui/gnome-thumbnail.h> > Functionality is now provided by gnome-desktop. Should be trivial. > See any of the <libgnomeui/gnome-desktop-thumbnail.h> port > examples already existing in g-c-c. > > ./libslab/document-tile.c:#include <libgnomeui/gnome-icon-lookup.h> > One match that should be trivial to fix: > icon_id = gnome_icon_lookup ( > gtk_icon_theme_get_default (), thumbnail_factory, > TILE (tile)->uri, NULL, NULL, priv->mime_type, 0, NULL); Those seem to be taken care of already in the seperate libslab module: http://git.gnome.org/cgit/libslab/commit/?id=41e246d9adcea93eb8ab46272c49b1fc5929c6e3
Created attachment 139172 [details] [review] patch for last comment When committing please set Cosimo Cecchi as author.
Last patch is in master: 40d465c3db067124710f9856375512835fa4602b Realized that I should have set author when git commit, not git push. Sigh. Sorry Cosimo. :-/
WORK LEFT: ./shell/control-center.c:#include <libgnomeui/libgnomeui.h> This generic header should be <libgnomeui/gnome-ui-init.h> instead as this seems to be only about using gnome_ui_init() once. ./libslab/app-shell.c:#include <libgnomeui/libgnomeui.h> This generic header should be <libgnomeui/gnome-app.h> instead.
./libslab/app-shell.c:#include <libgnomeui/libgnomeui.h> This generic header should be <libgnomeui/gnome-app.h> instead. This one has also already been fixed, see those two commits http://git.gnome.org/cgit/libslab/commit/?id=5157956a19ef050266a7d9603a6045c2f976f92c and http://git.gnome.org/cgit/libslab/commit/?id=a47610e0cae0000e4b64a859df38b455d5dee41c Still it might be good to have the situation in libslab a bit better clarified, should gnome-control-center actually use the external libslab? Or the internal one? For instance in gnome-main-menu the whole libslab-code has recently been ripped out...
Internal. gnome-main-menu? Is that still alive?
(In reply to comment #10) > Internal. > > gnome-main-menu? Is that still alive? > Well then, why have all the recent bugfixes only been commited to the standalone libslab project ;) @gnome-main-menu: Cosimo has been doing some libgnome-cleanups there recently...
Ah. Yeah, Federico now told me that he wants to publish a tarball for libslab (not: gnome-main-menu). Plans change every week, not bad though. :-P
All changes in libslab should indeed go to the standalone libslab module. The plan is to either use it or just copy it to g-c-c for every release, so make sure all changes go to the standalone module, please
(In reply to comment #9) > ./libslab/app-shell.c:#include <libgnomeui/libgnomeui.h> > This generic header should be <libgnomeui/gnome-app.h> instead. > This one has also already been fixed Copied to gnome-control-center: http://git.gnome.org/cgit/gnome-control-center/commit/?id=6b76c6a770784130e97a8344613391232698afd3 ========== WORK LEFT: ========== ./shell/control-center.c:#include <libgnomeui/libgnomeui.h> This generic header should be <libgnomeui/gnome-ui-init.h> instead as this seems to be only about using gnome_ui_init() once.
Created attachment 140104 [details] [review] Remove remaining libgnomeui-usage in control-center > ========== > WORK LEFT: > ========== > ./shell/control-center.c:#include <libgnomeui/libgnomeui.h> > This generic header should be <libgnomeui/gnome-ui-init.h> instead > as this seems to be only about using gnome_ui_init() once. With Bonobo gone this should be trivial now, attached patch works fine for me. But you might double check, not a coder myself ;)
Created attachment 140107 [details] [review] Updated patch to remove the remaining libgnomeui usage Just a quick update: Removed the corresponding check in configure.in Also I've taken out the libgnomeui-check in relation to the font viewer in configure.in as this seems to be bogus. libgnomeui usage here has been taken out months ago (see: http://git.gnome.org/cgit/gnome-control-center/commit/?id=8cff6042abbe39b95337430e9001f9181c206176 ), guess leaving the configure-check was just an oversight. Also can't find any libgnomeui-usage in font-viewer. After that gnome-control-center should be finally free of libgnome|ui usage :)
Committed as f7334d30ce739012385f2cd858c9d6ae8b8cba48 to master. Closing as FIXED.