All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [RfC PATCH] gtk: prefer version 3.x
@ 2016-07-07  7:34 Gerd Hoffmann
  2016-07-07  9:29 ` Daniel P. Berrange
  0 siblings, 1 reply; 4+ messages in thread
From: Gerd Hoffmann @ 2016-07-07  7:34 UTC (permalink / raw)
  To: qemu-devel; +Cc: Gerd Hoffmann

This patch flips the default from gtk2 to gtk3.

Sounds like a bigger change than it actually is as configure already
uses gtk3 in case it doesn't find gtk2.  So this changes behavior
only in case both gtk2 and gtk3 devel packages are installed.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
 configure | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/configure b/configure
index e9090a0..e029eee 100755
--- a/configure
+++ b/configure
@@ -2154,11 +2154,9 @@ fi
 # GTK probe
 
 if test "$gtkabi" = ""; then
-    # The GTK ABI was not specified explicitly, so try whether 2.0 is available.
-    # Use 3.0 as a fallback if that is available.
-    if $pkg_config --exists "gtk+-2.0 >= 2.18.0"; then
-        gtkabi=2.0
-    elif $pkg_config --exists "gtk+-3.0 >= 3.0.0"; then
+    # The GTK ABI was not specified explicitly, so try whether 3.0 is available.
+    # Use 2.0 as a fallback.
+    if $pkg_config --exists "gtk+-3.0 >= 3.0.0"; then
         gtkabi=3.0
     else
         gtkabi=2.0
-- 
1.8.3.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] [RfC PATCH] gtk: prefer version 3.x
  2016-07-07  7:34 [Qemu-devel] [RfC PATCH] gtk: prefer version 3.x Gerd Hoffmann
@ 2016-07-07  9:29 ` Daniel P. Berrange
  2016-07-07  9:57   ` Peter Maydell
  2016-07-07 14:27   ` Gerd Hoffmann
  0 siblings, 2 replies; 4+ messages in thread
From: Daniel P. Berrange @ 2016-07-07  9:29 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: qemu-devel

On Thu, Jul 07, 2016 at 09:34:47AM +0200, Gerd Hoffmann wrote:
> This patch flips the default from gtk2 to gtk3.
> 
> Sounds like a bigger change than it actually is as configure already
> uses gtk3 in case it doesn't find gtk2.  So this changes behavior
> only in case both gtk2 and gtk3 devel packages are installed.

As a point of note, GTK 3.0 was released in 2011, so its had 5 years
to get into distros now, which is more than enough for QEMU to consider
it a valid default choice over GTK 2.x

> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
> ---
>  configure | 8 +++-----
>  1 file changed, 3 insertions(+), 5 deletions(-)
> 
> diff --git a/configure b/configure
> index e9090a0..e029eee 100755
> --- a/configure
> +++ b/configure
> @@ -2154,11 +2154,9 @@ fi
>  # GTK probe
>  
>  if test "$gtkabi" = ""; then
> -    # The GTK ABI was not specified explicitly, so try whether 2.0 is available.
> -    # Use 3.0 as a fallback if that is available.
> -    if $pkg_config --exists "gtk+-2.0 >= 2.18.0"; then
> -        gtkabi=2.0
> -    elif $pkg_config --exists "gtk+-3.0 >= 3.0.0"; then
> +    # The GTK ABI was not specified explicitly, so try whether 3.0 is available.
> +    # Use 2.0 as a fallback.
> +    if $pkg_config --exists "gtk+-3.0 >= 3.0.0"; then
>          gtkabi=3.0
>      else
>          gtkabi=2.0

Reviewed-by: Daniel P. Berrange <berrange@redhat.com>


I'd further suggest that you might want to explicitly say that GTK-2.0
support is deprecated, and set a date for its removal, as its days are
clearly numbered, and it'd let us take advantage of more advanced GTK
3.0 features without piling on yet more #ifdefs.

Perhaps print a warning in configure to say GTK-2.0 will be removed in
the first release of 2018, if people use --with-gtkabi=2.0

Regards,
Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] [RfC PATCH] gtk: prefer version 3.x
  2016-07-07  9:29 ` Daniel P. Berrange
@ 2016-07-07  9:57   ` Peter Maydell
  2016-07-07 14:27   ` Gerd Hoffmann
  1 sibling, 0 replies; 4+ messages in thread
From: Peter Maydell @ 2016-07-07  9:57 UTC (permalink / raw)
  To: Daniel P. Berrange; +Cc: Gerd Hoffmann, QEMU Developers

On 7 July 2016 at 10:29, Daniel P. Berrange <berrange@redhat.com> wrote:
> On Thu, Jul 07, 2016 at 09:34:47AM +0200, Gerd Hoffmann wrote:
>> This patch flips the default from gtk2 to gtk3.
>>
>> Sounds like a bigger change than it actually is as configure already
>> uses gtk3 in case it doesn't find gtk2.  So this changes behavior
>> only in case both gtk2 and gtk3 devel packages are installed.
>
> As a point of note, GTK 3.0 was released in 2011, so its had 5 years
> to get into distros now, which is more than enough for QEMU to consider
> it a valid default choice over GTK 2.x

Yeah, even debian oldstable has a gtk 3.0...

thanks
-- PMM

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] [RfC PATCH] gtk: prefer version 3.x
  2016-07-07  9:29 ` Daniel P. Berrange
  2016-07-07  9:57   ` Peter Maydell
@ 2016-07-07 14:27   ` Gerd Hoffmann
  1 sibling, 0 replies; 4+ messages in thread
From: Gerd Hoffmann @ 2016-07-07 14:27 UTC (permalink / raw)
  To: Daniel P. Berrange; +Cc: qemu-devel

  Hi,

> I'd further suggest that you might want to explicitly say that GTK-2.0
> support is deprecated, and set a date for its removal, as its days are
> clearly numbered, and it'd let us take advantage of more advanced GTK
> 3.0 features without piling on yet more #ifdefs.

Good idea.

> Perhaps print a warning in configure to say GTK-2.0 will be removed in
> the first release of 2018, if people use --with-gtkabi=2.0

I guess a warning is easily overlooked.  New RfC patch follows in a
moment ...

cheers,
  Gerd

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2016-07-07 14:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-07  7:34 [Qemu-devel] [RfC PATCH] gtk: prefer version 3.x Gerd Hoffmann
2016-07-07  9:29 ` Daniel P. Berrange
2016-07-07  9:57   ` Peter Maydell
2016-07-07 14:27   ` Gerd Hoffmann

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.