GNOME Bugzilla – Bug 624570
Make it possible to build libgcr against GTK+ 3
Last modified: 2010-09-01 03:20:30 UTC
It should be possible to have a version of libgcr built against GTK+ 3, so consumers (seahorse & gnome-keyring) can be ported to GTK+ 3. http://mail.gnome.org/archives/desktop-devel-list/2010-June/msg00142.html has instructions by Alexander Larsson on converting libraries to gtk3; do note it lacks a point about .mo files, they should also be made parallel-installable.
This is also needed for Empathy (bug #627916). Without a GTK3 version of libgcr Empathy 2.32 won't be able to build with GTK3.
Created attachment 168737 [details] [review] Squashed diff of the 624570-gtk3 branch http://git.collabora.co.uk/?p=user/pwith/gnome-keyring;a=shortlog;h=refs/heads/624570-gtk3
Thanks for working on this Philip. However I think we need an --enable-gtk3 flag to configure, so that gnome-keyring can still be used in all the distributions that are not yet shipping GTK+ 2.90. I cherry-picked the other 4 cleanup commits in your 624570-gtk3 branch.
If you need an example of the configure/makefile glue to build the lib for both gtk's, librsvg's commit http://git.gnome.org/browse/librsvg/commit/?id=9a7292daf337e4da4eacf62edb45f34c28d11df2 provides one.
Aargh, Bugzilla failed to add me to the CC list. I'll see if I can update my branch tomorrow; I doubt I'll have time for it today. Thanks.
Created attachment 169152 [details] [review] Port gnome-keyring to GTK+ 3 Updated branch. This adds a --with-gtk=[2.0|3.0] option, and also ensures that links from gnome-keyring → gnome-keyring-1 and gnome-keyring-prompt → gnome-keyring-prompt-1 exist. It also changes the libgcr major version used with GTK+ 3 from 3 (in the original patch) to 1, since that's what Empathy now checks for (and it also seems a bit wasteful to skip two perfectly good major version numbers). http://git.collabora.co.uk/?p=user/pwith/gnome-keyring;a=shortlog;h=refs/heads/624570-gtk3-option
I've updated the branch slightly to add some checks before making symbolic links and to ensure HAVE_GTK3 is defined by AM_CONDITIONAL rather than AC_SUBST. Please say if you want an updated patch.
To me having gnome-keyring-1 be part of GNOME 3.0 is confusing. gnome-keyring-3 would make more sense, to me since it doesn't signify a difference in its own API, but the fact that it depends on GTK+ 3. We already 'wasted' lots of version numbers when syncing up with GNOME's version scheme. :) Also generally our conditionals are called WITH_XXX instead of HAVE_XXX. Other than that the branch looks good. I could make those changes as I merge, but wanted to check with you that there isn't something I'm missing about the xxx-1 vs. xxx-3 naming scheme.
(In reply to comment #8) > To me having gnome-keyring-1 be part of GNOME 3.0 is confusing. gnome-keyring-3 > would make more sense, to me since it doesn't signify a difference in its own > API, but the fact that it depends on GTK+ 3. > > We already 'wasted' lots of version numbers when syncing up with GNOME's > version scheme. :) Fair enough. I switched to GCR_MAJOR=1 because Empathy now looks for gcr-1 when building with GTK+ 3[1], but that can easily be changed, so please go for the version number you want. > Also generally our conditionals are called WITH_XXX instead of HAVE_XXX. OK. > Other than that the branch looks good. I could make those changes as I merge, > but wanted to check with you that there isn't something I'm missing about the > xxx-1 vs. xxx-3 naming scheme. No, the version number was chosen purely because Empathy's looking for it[1], but that can be changed, so please go ahead and merge! :) [1]: http://git.gnome.org/browse/empathy/commit/?id=32905fa2cb9fb3419f50c5894ac7507fb9330f8f
Merged with changes mentioned above. Thanks again Philip. Much appreciated.