After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 622303 - Allow building with Gtk+-3.0
Allow building with Gtk+-3.0
Status: RESOLVED FIXED
Product: mutter
Classification: Core
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: mutter-maint
mutter-maint
Depends on: 587991
Blocks:
 
 
Reported: 2010-06-21 17:46 UTC by Florian Müllner
Modified: 2010-07-02 13:55 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Allow building with Gtk+-3.0 (3.44 KB, patch)
2010-06-21 17:46 UTC, Florian Müllner
committed Details | Review

Description Florian Müllner 2010-06-21 17:46:38 UTC
Add a configure switch to compile against Gtk+-3.0 - if omitted, --with-gtk=2.0 is assumed.

Apart from the remaining patches in bug 587991, there is an open question about GdkPixbuf usage in Clutter - it doesn't affect the patch directly though, so filing anyway ...
Comment 1 Florian Müllner 2010-06-21 17:46:42 UTC
Created attachment 164234 [details] [review]
Allow building with Gtk+-3.0

Add a configure switch to select the Gtk+ version to build with. The
default is to build against Gtk+-2.0 >= 2.18.
Comment 2 Owen Taylor 2010-06-24 18:27:55 UTC
Review of attachment 164234 [details] [review]:

Looks good. OK to commit other than the comment below, and the gdk-pixbuf issue. (Talking to mclasen, sounds like the rough plan is to split a gdk-pixbuf library out and share it between GTK+ 2 and GTK+ 3)

Two things I thought about reviewing this:

 - Should it autodetect and compile against whatever of GTK+-2.0 and GTK+-3.0 is available?

   => Doesn't seem relevant - systems without GTK+ 2 are going to be uncommon for a long time. And it's a source of weird behavior and unreproducible builds.

 - Should we do parallel install of Mutter-built-against-GTK+-2.0 and Mutter-built-against-GTK+-3.0

   => Far too much work. Not interesting for GNOME Shell. I think systems that want to share a Mutter package between Moblin and GNOME Shell (which isn't currently possible anyways), will  have to figure out to get everything using common libraries.

::: configure.in
@@ +127,3 @@
+AC_MSG_CHECKING([which gtk+ version to compile against])
+AC_ARG_WITH([gtk],
+  AC_HELP_STRING([--with-gtk=2.0|3.0],

I think I'd rather see this as --with-gtk=2|3

The ".0" in the API version is a historical curiousity (GTK+-1.0 and 1.2 were incompatible)

It's fine to keep the .0 in the rest of the patch - just the configure argument.
Comment 3 Florian Müllner 2010-06-24 19:31:06 UTC
(In reply to comment #2)
> (Talking to mclasen, sounds like the rough plan is to split a gdk-pixbuf
> library out and share it between GTK+ 2 and GTK+ 3)

Yeah, that's what ebassi said as well.


> ::: configure.in
> @@ +127,3 @@
> +AC_MSG_CHECKING([which gtk+ version to compile against])
> +AC_ARG_WITH([gtk],
> +  AC_HELP_STRING([--with-gtk=2.0|3.0],
> 
> I think I'd rather see this as --with-gtk=2|3

I would agree if I had actually written that snippet myself - it is used in other modules as well and all use the .0 version (librsvg, vte, gnome-terminal, gucharmap). I think we should either run with the crowd or make the crowd run with us - having a common configure switch with a different set of allowed arguments is just unnecessarily confusing and inconvenient.
Comment 4 Owen Taylor 2010-06-24 19:43:00 UTC
(In reply to comment #3)
> 
> > ::: configure.in
> > @@ +127,3 @@
> > +AC_MSG_CHECKING([which gtk+ version to compile against])
> > +AC_ARG_WITH([gtk],
> > +  AC_HELP_STRING([--with-gtk=2.0|3.0],
> > 
> > I think I'd rather see this as --with-gtk=2|3
> 
> I would agree if I had actually written that snippet myself - it is used in
> other modules as well and all use the .0 version (librsvg, vte, gnome-terminal,
> gucharmap). I think we should either run with the crowd or make the crowd run
> with us - having a common configure switch with a different set of allowed
> arguments is just unnecessarily confusing and inconvenient.

Make sense.
Comment 5 Florian Müllner 2010-07-02 13:55:20 UTC
Attachment 164234 [details] pushed as 01447d9 - Allow building with Gtk+-3.0