summaryrefslogtreecommitdiff
path: root/media-libs/clutter/files
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /media-libs/clutter/files
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.xz
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'media-libs/clutter/files')
-rw-r--r--media-libs/clutter/files/clutter-1.22.2-clutter_gdk_get_visual-2.patch32
-rw-r--r--media-libs/clutter/files/clutter-1.22.2-clutter_gdk_get_visual.patch109
-rw-r--r--media-libs/clutter/files/clutter-1.22.2-cogl-visual-xlib.patch130
-rw-r--r--media-libs/clutter/files/clutter-1.22.2-touchpad-detection.patch36
4 files changed, 307 insertions, 0 deletions
diff --git a/media-libs/clutter/files/clutter-1.22.2-clutter_gdk_get_visual-2.patch b/media-libs/clutter/files/clutter-1.22.2-clutter_gdk_get_visual-2.patch
new file mode 100644
index 00000000000..c857d9dc7c8
--- /dev/null
+++ b/media-libs/clutter/files/clutter-1.22.2-clutter_gdk_get_visual-2.patch
@@ -0,0 +1,32 @@
+From 19064c4f444ed3fd596580cb98876619133c7f22 Mon Sep 17 00:00:00 2001
+From: Emmanuele Bassi <ebassi@gnome.org>
+Date: Wed, 10 Jun 2015 19:13:13 +0100
+Subject: [PATCH 3/3] build: Reset interface_age
+
+We don't usually add symbols inside a stable branch, but given that the
+newly added clutter_gdk_get_visual() function is necessary to make
+Clutter work when embedded inside GTK running on nVidia binary drivers,
+I decided to break the rule. This requires resetting the interface age,
+so that the soname version changes.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=747489
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index ed67ea1..5b590ed 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -31,7 +31,7 @@ m4_define([clutter_micro_version], [3])
+ # ...
+ #
+ # • for development releases: keep clutter_interface_age to 0
+-m4_define([clutter_interface_age], [2])
++m4_define([clutter_interface_age], [0])
+
+ m4_define([clutter_binary_age], [m4_eval(100 * clutter_minor_version + clutter_micro_version)])
+
+--
+2.4.3
+
diff --git a/media-libs/clutter/files/clutter-1.22.2-clutter_gdk_get_visual.patch b/media-libs/clutter/files/clutter-1.22.2-clutter_gdk_get_visual.patch
new file mode 100644
index 00000000000..d157ac1ee69
--- /dev/null
+++ b/media-libs/clutter/files/clutter-1.22.2-clutter_gdk_get_visual.patch
@@ -0,0 +1,109 @@
+From ab63b30a9b1812b0e53bcddcd55f00fd507347dc Mon Sep 17 00:00:00 2001
+From: Emmanuele Bassi <ebassi@gnome.org>
+Date: Wed, 10 Jun 2015 12:02:13 +0100
+Subject: [PATCH 2/3] gdk: Add function to retrieve the GdkVisual
+
+Straight from Cogl.
+
+This allows us to propagate the GdkVisual Cogl and Clutter use to
+embedding toolkits, like GTK+.
+
+The function is annotated as being added to the 1.22 development
+cycle because it will be backported to the stable branch, so that
+downstream developers can package up a version of Clutter that does
+not crash on nVidia.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=747489
+(cherry picked from commit 2d5b5aa82aacab7cc523e5877afbb864592b7651)
+Signed-off-by: Emmanuele Bassi <ebassi@gnome.org>
+---
+ clutter/gdk/clutter-backend-gdk.c | 48 ++++++++++++++++++++++++++++++
+ clutter/gdk/clutter-gdk.h | 3 ++
+ doc/reference/clutter/clutter-sections.txt | 1 +
+ 3 files changed, 52 insertions(+)
+
+diff --git a/clutter/gdk/clutter-backend-gdk.c b/clutter/gdk/clutter-backend-gdk.c
+index 47bd671..01ba8cb 100644
+--- a/clutter/gdk/clutter-backend-gdk.c
++++ b/clutter/gdk/clutter-backend-gdk.c
+@@ -498,3 +498,51 @@ clutter_gdk_disable_event_retrieval (void)
+
+ disable_event_retrieval = TRUE;
+ }
++
++/**
++ * clutter_gdk_get_visual:
++ *
++ * Retrieves the #GdkVisual used by Clutter.
++ *
++ * This function should be used when embedding Clutter inside GDK-based
++ * foreign toolkits, to ensure that the visual applied to the #GdkWindow
++ * used to render the #ClutterStage is the correct one.
++ *
++ * Returns: (transfer none): a #GdkVisual instance
++ *
++ * Since: 1.22
++ */
++GdkVisual *
++clutter_gdk_get_visual (void)
++{
++ ClutterBackend *backend = clutter_get_default_backend ();
++ GdkScreen *screen;
++
++ if (backend == NULL)
++ {
++ g_critical ("The Clutter backend has not been initialised");
++ return NULL;
++ }
++
++ if (!CLUTTER_IS_BACKEND_GDK (backend))
++ {
++ g_critical ("The Clutter backend is not a GDK backend");
++ return NULL;
++ }
++
++ screen = CLUTTER_BACKEND_GDK (backend)->screen;
++ g_assert (screen != NULL);
++
++#if defined(GDK_WINDOWING_X11) && defined(COGL_HAS_XLIB_SUPPORT)
++ {
++ XVisualInfo *xvisinfo = cogl_clutter_winsys_xlib_get_visual_info ();
++ if (xvisinfo != NULL)
++ return gdk_x11_screen_lookup_visual (screen, xvisinfo->visualid);
++ }
++#endif
++
++ if (gdk_screen_get_rgba_visual (screen) != NULL)
++ return gdk_screen_get_rgba_visual (screen);
++
++ return gdk_screen_get_system_visual (screen);
++}
+diff --git a/clutter/gdk/clutter-gdk.h b/clutter/gdk/clutter-gdk.h
+index a009378..c5b979b 100644
+--- a/clutter/gdk/clutter-gdk.h
++++ b/clutter/gdk/clutter-gdk.h
+@@ -61,6 +61,9 @@ ClutterStage * clutter_gdk_get_stage_from_window (GdkWindow *window);
+ CLUTTER_AVAILABLE_IN_1_10
+ void clutter_gdk_disable_event_retrieval (void);
+
++CLUTTER_AVAILABLE_IN_1_22
++GdkVisual * clutter_gdk_get_visual (void);
++
+ G_END_DECLS
+
+ #endif /* __CLUTTER_GDK_H__ */
+diff --git a/doc/reference/clutter/clutter-sections.txt b/doc/reference/clutter/clutter-sections.txt
+index 327f185..d521dc1 100644
+--- a/doc/reference/clutter/clutter-sections.txt
++++ b/doc/reference/clutter/clutter-sections.txt
+@@ -1516,6 +1516,7 @@ clutter_gdk_handle_event
+ clutter_gdk_set_display
+ clutter_gdk_get_default_display
+ clutter_gdk_set_stage_foreign
++clutter_gdk_get_visual
+ </SECTION>
+
+ <SECTION>
+--
+2.4.3
+
diff --git a/media-libs/clutter/files/clutter-1.22.2-cogl-visual-xlib.patch b/media-libs/clutter/files/clutter-1.22.2-cogl-visual-xlib.patch
new file mode 100644
index 00000000000..52cf929a006
--- /dev/null
+++ b/media-libs/clutter/files/clutter-1.22.2-cogl-visual-xlib.patch
@@ -0,0 +1,130 @@
+From 44fc1c87489bb7bbe1d28eb0f551794db333e1fb Mon Sep 17 00:00:00 2001
+From: Emmanuele Bassi <ebassi@gnome.org>
+Date: Wed, 10 Jun 2015 11:55:50 +0100
+Subject: [PATCH 1/3] gdk: Use the Cogl visual on Xlib winsys
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+GDK 3.16 started selecting different visuals, to best comply with the
+requirements for OpenGL, and this has broken Clutter on GLX drivers that
+are fairly picky in how they select visuals and GLXFBConfig.
+
+GDK selects GLXFBConfig that do not include depth or stencil buffers;
+Cogl, on the other hand, needs both depth and stencil buffers, and keeps
+selecting the first available visual, assuming that the GLX driver will
+give us the best compliant one, as per specification. Sadly, some
+drivers will return incompatible configurations, and then bomb out when
+you try to embed Clutter inside GTK+, because of mismatched visuals.
+
+Cogl has an old, deprecated, Clutter-only API that allows us to retrieve
+the XVisualInfo mapping to the GLXFBConfig it uses; this means we should
+look up the GdkVisual for it when creating our own GdkWindows, instead
+of relying on the RGBA and system GdkVisuals exposed by GDK — at least
+on X11.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=747489
+(cherry picked from commit c91621e8c28bb190eaa9d59e08b180589a255cf3)
+Signed-off-by: Emmanuele Bassi <ebassi@gnome.org>
+---
+ clutter/gdk/clutter-stage-gdk.c | 50 ++++++++++++++++++++++++++++++-----------
+ 1 file changed, 37 insertions(+), 13 deletions(-)
+
+diff --git a/clutter/gdk/clutter-stage-gdk.c b/clutter/gdk/clutter-stage-gdk.c
+index e855a98..82f7679 100644
+--- a/clutter/gdk/clutter-stage-gdk.c
++++ b/clutter/gdk/clutter-stage-gdk.c
+@@ -29,6 +29,10 @@
+
+ #include <cogl/cogl.h>
+
++#ifdef COGL_HAS_XLIB_SUPPORT
++#include <cogl/cogl-xlib.h>
++#endif
++
+ #define GDK_DISABLE_DEPRECATION_WARNINGS
+
+ #include <gdk/gdk.h>
+@@ -183,7 +187,7 @@ clutter_stage_gdk_realize (ClutterStageWindow *stage_window)
+ GdkWindowAttr attributes;
+ gboolean cursor_visible;
+ gboolean use_alpha;
+- gfloat width, height;
++ gfloat width, height;
+
+ if (backend->cogl_context == NULL)
+ {
+@@ -191,12 +195,7 @@ clutter_stage_gdk_realize (ClutterStageWindow *stage_window)
+ return FALSE;
+ }
+
+- if (stage_gdk->foreign_window)
+- {
+- width = gdk_window_get_width (stage_gdk->window);
+- height = gdk_window_get_height (stage_gdk->window);
+- }
+- else
++ if (!stage_gdk->foreign_window)
+ {
+ if (stage_gdk->window != NULL)
+ {
+@@ -239,13 +238,34 @@ clutter_stage_gdk_realize (ClutterStageWindow *stage_window)
+ attributes.cursor = stage_gdk->blank_cursor;
+ }
+
+- attributes.visual = NULL;
++ /* If the ClutterStage:use-alpha is set, but GDK does not have an
++ * RGBA visual, then we unset the property on the Stage
++ */
+ if (use_alpha)
+ {
+- attributes.visual = gdk_screen_get_rgba_visual (backend_gdk->screen);
++ if (gdk_screen_get_rgba_visual (backend_gdk->screen) == NULL)
++ {
++ clutter_stage_set_use_alpha (stage_cogl->wrapper, FALSE);
++ use_alpha = FALSE;
++ }
++ }
+
+- if (attributes.visual == NULL)
+- clutter_stage_set_use_alpha (stage_cogl->wrapper, FALSE);
++#if defined(GDK_WINDOWING_X11) && defined(COGL_HAS_XLIB_SUPPORT)
++ if (GDK_IS_X11_DISPLAY (backend_gdk->display))
++ {
++ XVisualInfo *xvisinfo = cogl_clutter_winsys_xlib_get_visual_info ();
++ if (xvisinfo != NULL)
++ {
++ attributes.visual = gdk_x11_screen_lookup_visual (backend_gdk->screen,
++ xvisinfo->visualid);
++ }
++ }
++ else
++#endif
++ {
++ attributes.visual = use_alpha
++ ? gdk_screen_get_rgba_visual (backend_gdk->screen)
++ : gdk_screen_get_system_visual (backend_gdk->screen);
+ }
+
+ if (attributes.visual == NULL)
+@@ -263,11 +283,15 @@ clutter_stage_gdk_realize (ClutterStageWindow *stage_window)
+
+ clutter_stage_gdk_set_gdk_geometry (stage_gdk);
+ }
++ else
++ {
++ width = gdk_window_get_width (stage_gdk->window);
++ height = gdk_window_get_height (stage_gdk->window);
++ }
+
+ gdk_window_ensure_native (stage_gdk->window);
+
+- g_object_set_data (G_OBJECT (stage_gdk->window),
+- "clutter-stage-window", stage_gdk);
++ g_object_set_data (G_OBJECT (stage_gdk->window), "clutter-stage-window", stage_gdk);
+
+ stage_cogl->onscreen = cogl_onscreen_new (backend->cogl_context,
+ width, height);
+--
+2.4.3
+
diff --git a/media-libs/clutter/files/clutter-1.22.2-touchpad-detection.patch b/media-libs/clutter/files/clutter-1.22.2-touchpad-detection.patch
new file mode 100644
index 00000000000..ad65105b13c
--- /dev/null
+++ b/media-libs/clutter/files/clutter-1.22.2-touchpad-detection.patch
@@ -0,0 +1,36 @@
+From a4aad807d5cc6842043e12897cfac3a516825c0f Mon Sep 17 00:00:00 2001
+From: Rui Matos <tiagomatos@gmail.com>
+Date: Sun, 17 May 2015 00:50:56 +0200
+Subject: [PATCH] x11: Fix touchpad detection
+
+Commit 79849ef1d5fff9acd310cd68d59df0c7cf2cb28f had a typo in the
+device property format check. This property is formated in 8-bit
+items, not 32-bit.
+
+This went unnoticed till now because some touchpads were still being
+detected as such due to a second check below:
+
+ else if (strstr (name, "touchpad") != NULL)
+ source = CLUTTER_TOUCHPAD_DEVICE;
+
+https://bugzilla.gnome.org/show_bug.cgi?id=749482
+---
+ clutter/x11/clutter-device-manager-xi2.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/clutter/x11/clutter-device-manager-xi2.c b/clutter/x11/clutter-device-manager-xi2.c
+index 17c491e..1b101c4 100644
+--- a/clutter/x11/clutter-device-manager-xi2.c
++++ b/clutter/x11/clutter-device-manager-xi2.c
+@@ -242,7 +242,7 @@ is_touchpad_device (ClutterBackendX11 *backend_x11,
+ /* We don't care about the data */
+ XFree (data);
+
+- if (rc != Success || type != XA_INTEGER || format != 32 || nitems != 1)
++ if (rc != Success || type != XA_INTEGER || format != 8 || nitems != 1)
+ return FALSE;
+
+ return TRUE;
+--
+2.4.3
+