GNOME Goal: Remove deprecated GTK+ symbols
Summary
The goal is to remove the deprecated GTK+, GDK and gdk-pixbuf symbols (functions, structs, macros, etc.) and replace them with something that fits better (usually a newer symbol). This has to be done for each GNOME module (application or library).
Guidelines
Compile your application with :
make CFLAGS+="-DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED"
For help on these symbols, you may give a look to the lists of deprecated symbols in gdk-pixbuf, GDK 2 and GTK+ 2. Those lists are generated automatically and always up-to-date.
Guidelines for modules written in C/C++
Step 1: Detect if the module uses deprecated symbols
You don't need to compile the module for that. Just get its source code, a file that contains the deprecated symbols to look for, and use the git grep command to look for deprecated symbols in the module source code.
For example, the following command uses a file that contains the name of the deprecated symbols, and looks for them in each source file:
git grep -w -f deprecated-gtk-2.24-symbols.txt
You may download files that lists those deprecated symbols for use with the above command:
Module |
Version |
Deprecated symbols file |
GTK+ |
2.24 |
|
GDK |
2.24 |
|
gdk-pixbuf |
2.24 |
Step 2: Compile the module
Compile the module without doing any modifications, just to make sure you're able to compile it without errors. You should be able to compile it alone.
Step 3: Compile the module with the deprecated symbols disabled
Compile the module again, but this time, define the GDK_PIXBUF_DISABLE_DEPRECATED, GDK_DISABLE_DEPRECATED and GTK_DISABLE_DEPRECATED symbol, which will disable deprecated GTK+, gdk-pixbuf and gdk symbols. There's more than one way to do it. You can for example use :
make CFLAGS+="-DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED"
If you're using Jhbuild, you can make him use this setting by adding the following line to your .jhbuildrc (and putting the right module name)
module_makeargs['name-of-the-module'] = makeargs + 'CFLAGS+="-DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED"'
If your module uses the GNOME autoconf macros, you can ensure GNOME_MAINTAINER_MODE_DEFINES is used in your configure.in, and that $(DISABLE_DEPRECATED) is included in the *_CPPFLAGS variables for all your compilation targets. $(DISABLE_DEPRECATED) is defined by GNOME_MAINTAINER_MODE_DEFINES, and has *_DISABLE_DEPRECATED flags for GTK+, GDK+ and GLib, amongst others.
To enable compilation with GDK_PIXBUF_DISABLE_DEPRECATED, GDK_DISABLE_DEPRECATED and GTK_DISABLE_DEPRECATED defined, simply pass the --enable-maintainer-mode argument when calling the configure script. If using jhbuild, you can put it in the module_autogenargs string for your module in your .jhbuildrc:
module_autogenargs['name-of-the-module'] = autogenargs + ' --enable-maintainer-mode'
Step 4: Replace the obsolete symbols by something that works and that is not deprecated
This is where most of the work takes place. There are several different deprecated symbols, so there's no single answer on how to do it. Sometimes the API documentation will give you the answer, or an hint, and sometimes you'll have to think by yourself.
Status of this goal
Tip: If you choose to work on a module, create the bug report on the GNOME bugzilla and mark it as blocking this tracker bug. |
State |
Markup |
todo |
<: #ff8080> todo |
patch |
<: #ffc849> [GnomeBug:xxxxx patch] |
done |
<: #80ff80> [GnomeBug:xxxxx done] |
not needed |
<: #80ff80> not needed |
Above are the states and corresponding markup to update the modules state table below.
Tarball |
Status |
|
Desktop |
||
alacarte |
not needed |
|
brasero |
||
bug-buddy |
not needed |
|
dasher |
||
done |
||
not needed |
||
not needed |
||
evolution-data-server |
||
evolution-exchange |
done |
|
evolution-mapi |
done |
|
evolution-webcal |
||
file-roller |
||
gcalctool |
done |
|
gconf-editor |
done |
|
gnome-backgrounds |
not needed |
|
gnome-desktop |
not needed |
|
not needed |
||
gnome-icon-theme |
not needed |
|
gnome-keyring |
done |
|
gnome-netstatus |
||
gnome-nettool |
||
gnome-mag |
done |
|
gnome-menus |
not needed |
|
gnome-power-manager |
done |
|
gnome-python-desktop |
done |
|
done |
||
gnome-session |
done |
|
gnome-settings-daemon |
||
not needed |
||
gnome-system-monitor |
||
gnome-terminal |
||
not needed |
||
gnome-user-docs |
not needed |
|
gnome-user-share |
||
gst-plugins-base |
||
gst-plugins-good |
||
gtk-engines |
fixed in 2.90 |
|
gtkhtml |
||
not needed |
||
not needed |
||
gvfs |
not needed |
|
hamster |
done |
|
libgail-gnome |
done |
|
libgnomekbd |
||
libgtop |
not needed |
|
done |
||
liboobs |
done |
|
librsvg |
||
not needed |
||
libwnck |
done |
|
metacity |
||
mousetweaks |
done |
|
orca |
done |
|
pygtksourceview |
done |
|
seahorse-plugins |
||
swfdec-gnome |
done |
|
tomboy |
done |
|
totem-pl-parser |
not needed |
|
done |
||
vinagre |
done |
|
vino |
||
vte |
not needed |
|
Desktop (to be deprecated) |
||
libgnomeprint |
not needed |
not used in 2.27 anymore |
libgnomeprintui |
not needed |
not used in 2.27 anymore |
Platform |
||
GConf |
||
at-spi |
||
atk |
not needed |
|
gail |
not needed |
merged into GTK+ |
glib |
not needed |
|
gnome-vfs |
not needed |
not used in 2.27 anymore |
not needed |
||
gtk-doc |
not needed |
|
intltool |
not needed |
|
libglade |
to do |
|
libxml2 |
not needed |
|
libxslt |
not needed |
|
pango |
||
pkgconfig |
not needed |
|
Platform (to be deprecated) |
||
ORBit2 |
not needed |
|
audiofile |
not needed |
|
esound |
not needed |
|
libIDL |
not needed |
|
libart_lgpl |
not needed |
|
libbonobo |
not needed |
|
libbonoboui |
to do |
|
libgnome |
to do |
|
libgnomecanvas |
||
libgnomeui |
to do |
|
Admin |
||
to do |
||
sabayon |
to do |
|
Development Tools |
||
accerciser |
done |
|
anjuta |
||
devhelp |
||
gdl |
||
glade3 |
||
gnome-devel-docs |
not needed |
|
Mobile |
||
gconf-dbus |
to do |
|
evolution-data-server-dbus |
to do |
|
Bindings (C++) |
||
glibmm |
to do |
|
gtkmm |
to do |
|
libglademm |
to do |
|
gconfmm |
to do |
|
libgnomecanvasmm |
to do |
|
libgnome-vfsmm |
to do |
|
libgnomemm |
to do |
|
libgnomeuimm |
to do |
|
libxml++ |
to do |
|
Bindings (java) |
||
glib-java (jg-common) |
to do |
|
libgtk-java |
to do |
|
libgnome-java |
to do |
|
libgconf-java |
to do |
|
libglade-java |
to do |
|
Bindings (perl) |
||
Glib |
not needed |
|
Gtk2 |
to do |
|
Gtk2-GladeXML |
||
Gnome2-GConf |
to do |
|
Gnome2-Canvas |
to do |
|
Gnome2-VFS |
to do |
|
Gnome2 |
to do |
|
Bindings (python) |
||
pygobject |
not needed |
|
gnome-python |
not needed |
|
Bindings (mono) |
||
gtk-sharp |
to do |
|
External dependencies |
||
PolicyKit-gnome |
done |
|
libcanberra |
||
Other |
||
abiword |
to do |
|
atomix |
to do |
|
balsa |
||
banshee |
not needed |
|
to do |
||
to do |
||
contact-lookup-applet |
to do |
|
eggcups |
to do |
|
f-spot |
||
gegl |
||
gimp |
||
glom |
||
gnome-blog |
to do |
|
to do |
||
gnome-cups-manager |
not needed |
|
gnome-main-menu |
to do |
|
to do |
||
goocanvas |
not needed |
only in commented code |
GParted |
not needed |
|
GNOME Phone Manager |
to do |
|
gnome-pilot |
||
to do |
||
gtetrinet |
||
gthumb |
||
krb5-auth-dialog |
to do |
|
leafpad |
||
libbtctl |
to do |
|
libgda |
done |
|
libgnomekbd |
||
libgoffice |
to do |
|
libgsf |
to do |
|
libslab |
||
modest |
||
mutter |
||
nautilus-sendto |
||
nautilus-vcs |
to do |
|
nemiver |
not needed |
|
network-manager-applet |
||
done |
||
planner |
||
tinymail |
||
tracker |
||
Transmission |
not needed |
|
webkit |
||