[arch-commits] Commit in clutter/repos (12 files)

Andreas Radke andyrtr at nymeria.archlinux.org
Sat Mar 8 16:54:51 UTC 2014


    Date: Saturday, March 8, 2014 @ 17:54:51
  Author: andyrtr
Revision: 207406

archrelease: copy trunk to staging-i686, staging-x86_64

Added:
  clutter/repos/staging-i686/
  clutter/repos/staging-i686/PKGBUILD
    (from rev 207405, clutter/trunk/PKGBUILD)
  clutter/repos/staging-i686/fix_a_segfault_on_device_removal.diff
    (from rev 207405, clutter/trunk/fix_a_segfault_on_device_removal.diff)
  clutter/repos/staging-i686/fix_buffer_age.patch
    (from rev 207405, clutter/trunk/fix_buffer_age.patch)
  clutter/repos/staging-i686/stop_using_deprecated_libevdev_api.diff
    (from rev 207405, clutter/trunk/stop_using_deprecated_libevdev_api.diff)
  clutter/repos/staging-i686/unref_devices_on_removal.diff
    (from rev 207405, clutter/trunk/unref_devices_on_removal.diff)
  clutter/repos/staging-x86_64/
  clutter/repos/staging-x86_64/PKGBUILD
    (from rev 207405, clutter/trunk/PKGBUILD)
  clutter/repos/staging-x86_64/fix_a_segfault_on_device_removal.diff
    (from rev 207405, clutter/trunk/fix_a_segfault_on_device_removal.diff)
  clutter/repos/staging-x86_64/fix_buffer_age.patch
    (from rev 207405, clutter/trunk/fix_buffer_age.patch)
  clutter/repos/staging-x86_64/stop_using_deprecated_libevdev_api.diff
    (from rev 207405, clutter/trunk/stop_using_deprecated_libevdev_api.diff)
  clutter/repos/staging-x86_64/unref_devices_on_removal.diff
    (from rev 207405, clutter/trunk/unref_devices_on_removal.diff)

--------------------------------------------------------+
 staging-i686/PKGBUILD                                  |   56 +++++++
 staging-i686/fix_a_segfault_on_device_removal.diff     |   31 +++
 staging-i686/fix_buffer_age.patch                      |   34 ++++
 staging-i686/stop_using_deprecated_libevdev_api.diff   |  117 +++++++++++++++
 staging-i686/unref_devices_on_removal.diff             |   22 ++
 staging-x86_64/PKGBUILD                                |   56 +++++++
 staging-x86_64/fix_a_segfault_on_device_removal.diff   |   31 +++
 staging-x86_64/fix_buffer_age.patch                    |   34 ++++
 staging-x86_64/stop_using_deprecated_libevdev_api.diff |  117 +++++++++++++++
 staging-x86_64/unref_devices_on_removal.diff           |   22 ++
 10 files changed, 520 insertions(+)

Copied: clutter/repos/staging-i686/PKGBUILD (from rev 207405, clutter/trunk/PKGBUILD)
===================================================================
--- staging-i686/PKGBUILD	                        (rev 0)
+++ staging-i686/PKGBUILD	2014-03-08 16:54:51 UTC (rev 207406)
@@ -0,0 +1,56 @@
+# $Id$
+# Maintainer: Jan de Groot <jgc at archlinux.org>
+# Contributor: Sergej Pupykin <pupykin.s+arch at gmail.com>
+# Contributor: William Rea <sillywilly at gmail.com>
+
+pkgname=clutter
+pkgver=1.16.4
+pkgrel=3
+pkgdesc="A GObject based library for creating fast, visually rich graphical user interfaces"
+arch=('i686' 'x86_64')
+url="http://clutter-project.org/"
+license=('LGPL')
+depends=('cogl' 'mesa' 'json-glib' 'atk' 'libxi' 'libxkbcommon' 'libevdev')
+makedepends=('gobject-introspection')
+source=(http://download.gnome.org/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.xz
+        fix_buffer_age.patch
+        unref_devices_on_removal.diff
+        fix_a_segfault_on_device_removal.diff
+        stop_using_deprecated_libevdev_api.diff)
+sha256sums=('cf50836ec5503577b73f75f984577610881b3e2ff7a327bb5b6918b431b51b65'
+            'e254b26663c88dfba756934f011451c0551e52bb70e2de037835aea267ed7bda'
+            '70494fe0b46bbe4157196fd855e3fcef0970e543979018df57676fea00dd38af'
+            'a9dabecb727f23654ef622aef8bba92e3dd1381ef6257107da7a689766e9917c'
+            '02768f0032f57939caa3f0695723fd3a6b4ab7bb33908ca50502dfc7f49e6c21')
+
+prepare() {
+  cd "$pkgname-$pkgver"
+  patch -Np1 -i ../fix_buffer_age.patch
+  
+  # fix build with libevdev >= 1.0.x
+  # https://git.gnome.org/browse/clutter/commit/?h=clutter-1.18&id=7d8f72a60e4087a4d9e48d3f0e38b669b3717243
+  patch -Np1 -i ../unref_devices_on_removal.diff
+  # https://git.gnome.org/browse/clutter/patch/?id=05e6bcc666e345ed4619c1a40a298212d1075b99
+  patch -Np1 -i ../fix_a_segfault_on_device_removal.diff
+  # https://git.gnome.org/browse/clutter/patch/?id=3cd9a70fea1ccf795419a1726c7c279b0aaf237e
+  patch -Np1 -i ../stop_using_deprecated_libevdev_api.diff
+  
+  autoreconf -vfi
+}
+
+build() {
+  cd "$pkgname-$pkgver"
+  ./configure --prefix=/usr --enable-introspection \
+    --enable-wayland-backend --enable-egl-backend --enable-evdev-input \
+    --enable-wayland-compositor
+
+  # https://bugzilla.gnome.org/show_bug.cgi?id=655517
+  sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
+
+  make
+}
+
+package() {
+  cd "$pkgname-$pkgver"
+  make DESTDIR="$pkgdir" install
+}

Copied: clutter/repos/staging-i686/fix_a_segfault_on_device_removal.diff (from rev 207405, clutter/trunk/fix_a_segfault_on_device_removal.diff)
===================================================================
--- staging-i686/fix_a_segfault_on_device_removal.diff	                        (rev 0)
+++ staging-i686/fix_a_segfault_on_device_removal.diff	2014-03-08 16:54:51 UTC (rev 207406)
@@ -0,0 +1,31 @@
+From 05e6bcc666e345ed4619c1a40a298212d1075b99 Mon Sep 17 00:00:00 2001
+From: Rui Matos <tiagomatos at gmail.com>
+Date: Thu, 21 Nov 2013 13:51:26 +0000
+Subject: device-manager-evdev: Fix a segfault on device removal
+
+Master devices have a NULL sysfs path so use g_strcmp0 to handle them
+without crashing.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=712812
+---
+diff --git a/clutter/evdev/clutter-device-manager-evdev.c b/clutter/evdev/clutter-device-manager-evdev.c
+index 256fd0e..38d707f 100644
+--- a/clutter/evdev/clutter-device-manager-evdev.c
++++ b/clutter/evdev/clutter-device-manager-evdev.c
+@@ -943,11 +943,8 @@ find_device_by_udev_device (ClutterDeviceManagerEvdev *manager_evdev,
+     {
+       ClutterInputDeviceEvdev *device = l->data;
+ 
+-      if (strcmp (sysfs_path,
+-                  _clutter_input_device_evdev_get_sysfs_path (device)) == 0)
+-        {
+-          return device;
+-        }
++      if (g_strcmp0 (sysfs_path, _clutter_input_device_evdev_get_sysfs_path (device)) == 0)
++        return device;
+     }
+ 
+   return NULL;
+--
+cgit v0.9.2
+

Copied: clutter/repos/staging-i686/fix_buffer_age.patch (from rev 207405, clutter/trunk/fix_buffer_age.patch)
===================================================================
--- staging-i686/fix_buffer_age.patch	                        (rev 0)
+++ staging-i686/fix_buffer_age.patch	2014-03-08 16:54:51 UTC (rev 207406)
@@ -0,0 +1,34 @@
+From 6665f47d66a871b6e1a5f4200282f42da043a0e8 Mon Sep 17 00:00:00 2001
+From: Adel Gadllah <adel.gadllah at gmail.com>
+Date: Sun, 16 Feb 2014 21:07:43 +0000
+Subject: stage-cogl: Fix buffer_age code path
+
+Currently we where checking whether the damage_history list contains
+more or equal then buffer_age entries. This is wrong because we prepend
+our current clip to the list just before the check.
+
+Fix that to check whether we have more entries instead of more or equal.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=724788
+---
+diff --git a/clutter/cogl/clutter-stage-cogl.c b/clutter/cogl/clutter-stage-cogl.c
+index 86546b1..cff8444 100644
+--- a/clutter/cogl/clutter-stage-cogl.c
++++ b/clutter/cogl/clutter-stage-cogl.c
+@@ -483,11 +483,12 @@ clutter_stage_cogl_redraw (ClutterStageWindow *stage_window)
+ 
+         stage_cogl->damage_history = g_slist_prepend (stage_cogl->damage_history, current_damage);
+ 
+-        if (age != 0 && !stage_cogl->dirty_backbuffer && g_slist_length (stage_cogl->damage_history) >= age)
++        if (age != 0 && !stage_cogl->dirty_backbuffer && g_slist_length (stage_cogl->damage_history) > age)
+           {
+             int i = 0;
+             GSList *tmp = NULL;
+-            for (tmp = stage_cogl->damage_history; tmp; tmp = tmp->next)
++            /* We skip the first entry because it is the clip_region itself */
++            for (tmp = stage_cogl->damage_history->next; tmp; tmp = tmp->next)
+               {
+                 _clutter_util_rectangle_union (clip_region, tmp->data, clip_region);
+                 i++;
+--
+cgit v0.9.2

Copied: clutter/repos/staging-i686/stop_using_deprecated_libevdev_api.diff (from rev 207405, clutter/trunk/stop_using_deprecated_libevdev_api.diff)
===================================================================
--- staging-i686/stop_using_deprecated_libevdev_api.diff	                        (rev 0)
+++ staging-i686/stop_using_deprecated_libevdev_api.diff	2014-03-08 16:54:51 UTC (rev 207406)
@@ -0,0 +1,117 @@
+From 3cd9a70fea1ccf795419a1726c7c279b0aaf237e Mon Sep 17 00:00:00 2001
+From: Rui Matos <tiagomatos at gmail.com>
+Date: Tue, 19 Nov 2013 16:02:58 +0000
+Subject: device-manager-evdev: Stop using deprecated libevdev API
+
+Fixes compiler warnings with libevdev >= 0.4 and makes use of a new
+function to set the clock id instead of doing the ioctl directly.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=712816
+---
+diff --git a/README.in b/README.in
+index 0018869..0e73a42 100644
+--- a/README.in
++++ b/README.in
+@@ -40,7 +40,7 @@ When building the CEx100 backend, Clutter also depends on:
+ When building the evdev input backend, Clutter also depends on:
+ 
+   • xkbcommon
+-  • libevdev
++  • libevdev ≥ @LIBEVDEV_REQ_VERSION@
+ 
+ If you are building the API reference you will also need:
+ 
+diff --git a/clutter/evdev/clutter-device-manager-evdev.c b/clutter/evdev/clutter-device-manager-evdev.c
+index 38d707f..bc34c39 100644
+--- a/clutter/evdev/clutter-device-manager-evdev.c
++++ b/clutter/evdev/clutter-device-manager-evdev.c
+@@ -605,11 +605,11 @@ sync_source (ClutterEventSource *source)
+   const gchar *device_path;
+ 
+   /* We read a SYN_DROPPED, ignore it and sync the device */
+-  err = libevdev_next_event (source->dev, LIBEVDEV_READ_SYNC, &ev);
++  err = libevdev_next_event (source->dev, LIBEVDEV_READ_FLAG_SYNC, &ev);
+   while (err == 1)
+     {
+       dispatch_one_event (source, &ev);
+-      err = libevdev_next_event (source->dev, LIBEVDEV_READ_SYNC, &ev);
++      err = libevdev_next_event (source->dev, LIBEVDEV_READ_FLAG_SYNC, &ev);
+     }
+ 
+   if (err != -EAGAIN && CLUTTER_HAS_DEBUG (EVENT))
+@@ -664,7 +664,7 @@ clutter_event_dispatch (GSource     *g_source,
+   if (clutter_events_pending ())
+     goto queue_event;
+ 
+-  err = libevdev_next_event (source->dev, LIBEVDEV_READ_NORMAL, &ev);
++  err = libevdev_next_event (source->dev, LIBEVDEV_READ_FLAG_NORMAL, &ev);
+   while (err != -EAGAIN)
+     {
+       if (err == 1)
+@@ -677,7 +677,7 @@ clutter_event_dispatch (GSource     *g_source,
+ 	  goto out;
+ 	}
+ 
+-      err = libevdev_next_event (source->dev, LIBEVDEV_READ_NORMAL, &ev);
++      err = libevdev_next_event (source->dev, LIBEVDEV_READ_FLAG_NORMAL, &ev);
+     }
+ 
+  queue_event:
+@@ -725,7 +725,7 @@ clutter_event_source_new (ClutterInputDeviceEvdev *input_device)
+   GSource *source = g_source_new (&event_funcs, sizeof (ClutterEventSource));
+   ClutterEventSource *event_source = (ClutterEventSource *) source;
+   const gchar *node_path;
+-  gint fd, clkid;
++  gint fd;
+   GError *error;
+   ClutterInputDeviceType device_type;
+ 
+@@ -756,15 +756,13 @@ clutter_event_source_new (ClutterInputDeviceEvdev *input_device)
+ 	}
+     }
+ 
+-  /* Tell evdev to use the monotonic clock for its timestamps */
+-  clkid = CLOCK_MONOTONIC;
+-  ioctl (fd, EVIOCSCLOCKID, &clkid);
+-
+   /* setup the source */
+   event_source->device = input_device;
+   event_source->event_poll_fd.fd = fd;
+   event_source->event_poll_fd.events = G_IO_IN;
++
+   libevdev_new_from_fd (fd, &event_source->dev);
++  libevdev_set_clock_id (event_source->dev, CLOCK_MONOTONIC);
+ 
+   device_type = clutter_input_device_get_device_type (CLUTTER_INPUT_DEVICE (input_device));
+   if (device_type == CLUTTER_TOUCHPAD_DEVICE)
+diff --git a/configure.ac b/configure.ac
+index 0448ee4..47fce79 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -146,6 +146,7 @@ m4_define([uprof_req_version],          [0.3])
+ m4_define([gtk_doc_req_version],        [1.15])
+ m4_define([xcomposite_req_version],     [0.4])
+ m4_define([gdk_req_version],            [3.3.18])
++m4_define([libevdev_req_version],       [0.4])
+ 
+ AC_SUBST([GLIB_REQ_VERSION],       [glib_req_version])
+ AC_SUBST([COGL_REQ_VERSION],       [cogl_req_version])
+@@ -158,6 +159,7 @@ AC_SUBST([UPROF_REQ_VERSION],      [uprof_req_version])
+ AC_SUBST([GTK_DOC_REQ_VERSION],    [gtk_doc_req_version])
+ AC_SUBST([XCOMPOSITE_REQ_VERSION], [xcomposite_req_version])
+ AC_SUBST([GDK_REQ_VERSION],        [gdk_req_version])
++AC_SUBST([LIBEVDEV_REQ_VERSION],   [libevdev_req_version])
+ 
+ # Checks for typedefs, structures, and compiler characteristics.
+ AM_PATH_GLIB_2_0([glib_req_version],
+@@ -478,7 +480,7 @@ AS_IF([test "x$enable_evdev" = "xyes"],
+         AS_IF([test "x$have_evdev" = "xyes"],
+               [
+                 CLUTTER_INPUT_BACKENDS="$CLUTTER_INPUT_BACKENDS evdev"
+-                BACKEND_PC_FILES="$BACKEND_PC_FILES gudev-1.0 libevdev xkbcommon"
++                BACKEND_PC_FILES="$BACKEND_PC_FILES gudev-1.0 libevdev >= $LIBEVDEV_REQ_VERSION xkbcommon"
+                 experimental_input_backend="yes"
+                 AC_DEFINE([HAVE_EVDEV], [1], [Have evdev support for input handling])
+                 SUPPORT_EVDEV=1
+--
+cgit v0.9.2

Copied: clutter/repos/staging-i686/unref_devices_on_removal.diff (from rev 207405, clutter/trunk/unref_devices_on_removal.diff)
===================================================================
--- staging-i686/unref_devices_on_removal.diff	                        (rev 0)
+++ staging-i686/unref_devices_on_removal.diff	2014-03-08 16:54:51 UTC (rev 207406)
@@ -0,0 +1,22 @@
+From 7d8f72a60e4087a4d9e48d3f0e38b669b3717243 Mon Sep 17 00:00:00 2001
+From: Rui Matos <tiagomatos at gmail.com>
+Date: Thu, 21 Nov 2013 13:50:40 +0000
+Subject: device-manager-evdev: Unref devices on removal
+
+https://bugzilla.gnome.org/show_bug.cgi?id=712812
+---
+diff --git a/clutter/evdev/clutter-device-manager-evdev.c b/clutter/evdev/clutter-device-manager-evdev.c
+index 9e7be95..256fd0e 100644
+--- a/clutter/evdev/clutter-device-manager-evdev.c
++++ b/clutter/evdev/clutter-device-manager-evdev.c
+@@ -1046,6 +1046,8 @@ clutter_device_manager_evdev_remove_device (ClutterDeviceManager *manager,
+       clutter_event_source_free (source);
+       priv->event_sources = g_slist_remove (priv->event_sources, source);
+     }
++
++  g_object_unref (device);
+ }
+ 
+ static const GSList *
+--
+cgit v0.9.2

Copied: clutter/repos/staging-x86_64/PKGBUILD (from rev 207405, clutter/trunk/PKGBUILD)
===================================================================
--- staging-x86_64/PKGBUILD	                        (rev 0)
+++ staging-x86_64/PKGBUILD	2014-03-08 16:54:51 UTC (rev 207406)
@@ -0,0 +1,56 @@
+# $Id$
+# Maintainer: Jan de Groot <jgc at archlinux.org>
+# Contributor: Sergej Pupykin <pupykin.s+arch at gmail.com>
+# Contributor: William Rea <sillywilly at gmail.com>
+
+pkgname=clutter
+pkgver=1.16.4
+pkgrel=3
+pkgdesc="A GObject based library for creating fast, visually rich graphical user interfaces"
+arch=('i686' 'x86_64')
+url="http://clutter-project.org/"
+license=('LGPL')
+depends=('cogl' 'mesa' 'json-glib' 'atk' 'libxi' 'libxkbcommon' 'libevdev')
+makedepends=('gobject-introspection')
+source=(http://download.gnome.org/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.xz
+        fix_buffer_age.patch
+        unref_devices_on_removal.diff
+        fix_a_segfault_on_device_removal.diff
+        stop_using_deprecated_libevdev_api.diff)
+sha256sums=('cf50836ec5503577b73f75f984577610881b3e2ff7a327bb5b6918b431b51b65'
+            'e254b26663c88dfba756934f011451c0551e52bb70e2de037835aea267ed7bda'
+            '70494fe0b46bbe4157196fd855e3fcef0970e543979018df57676fea00dd38af'
+            'a9dabecb727f23654ef622aef8bba92e3dd1381ef6257107da7a689766e9917c'
+            '02768f0032f57939caa3f0695723fd3a6b4ab7bb33908ca50502dfc7f49e6c21')
+
+prepare() {
+  cd "$pkgname-$pkgver"
+  patch -Np1 -i ../fix_buffer_age.patch
+  
+  # fix build with libevdev >= 1.0.x
+  # https://git.gnome.org/browse/clutter/commit/?h=clutter-1.18&id=7d8f72a60e4087a4d9e48d3f0e38b669b3717243
+  patch -Np1 -i ../unref_devices_on_removal.diff
+  # https://git.gnome.org/browse/clutter/patch/?id=05e6bcc666e345ed4619c1a40a298212d1075b99
+  patch -Np1 -i ../fix_a_segfault_on_device_removal.diff
+  # https://git.gnome.org/browse/clutter/patch/?id=3cd9a70fea1ccf795419a1726c7c279b0aaf237e
+  patch -Np1 -i ../stop_using_deprecated_libevdev_api.diff
+  
+  autoreconf -vfi
+}
+
+build() {
+  cd "$pkgname-$pkgver"
+  ./configure --prefix=/usr --enable-introspection \
+    --enable-wayland-backend --enable-egl-backend --enable-evdev-input \
+    --enable-wayland-compositor
+
+  # https://bugzilla.gnome.org/show_bug.cgi?id=655517
+  sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
+
+  make
+}
+
+package() {
+  cd "$pkgname-$pkgver"
+  make DESTDIR="$pkgdir" install
+}

Copied: clutter/repos/staging-x86_64/fix_a_segfault_on_device_removal.diff (from rev 207405, clutter/trunk/fix_a_segfault_on_device_removal.diff)
===================================================================
--- staging-x86_64/fix_a_segfault_on_device_removal.diff	                        (rev 0)
+++ staging-x86_64/fix_a_segfault_on_device_removal.diff	2014-03-08 16:54:51 UTC (rev 207406)
@@ -0,0 +1,31 @@
+From 05e6bcc666e345ed4619c1a40a298212d1075b99 Mon Sep 17 00:00:00 2001
+From: Rui Matos <tiagomatos at gmail.com>
+Date: Thu, 21 Nov 2013 13:51:26 +0000
+Subject: device-manager-evdev: Fix a segfault on device removal
+
+Master devices have a NULL sysfs path so use g_strcmp0 to handle them
+without crashing.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=712812
+---
+diff --git a/clutter/evdev/clutter-device-manager-evdev.c b/clutter/evdev/clutter-device-manager-evdev.c
+index 256fd0e..38d707f 100644
+--- a/clutter/evdev/clutter-device-manager-evdev.c
++++ b/clutter/evdev/clutter-device-manager-evdev.c
+@@ -943,11 +943,8 @@ find_device_by_udev_device (ClutterDeviceManagerEvdev *manager_evdev,
+     {
+       ClutterInputDeviceEvdev *device = l->data;
+ 
+-      if (strcmp (sysfs_path,
+-                  _clutter_input_device_evdev_get_sysfs_path (device)) == 0)
+-        {
+-          return device;
+-        }
++      if (g_strcmp0 (sysfs_path, _clutter_input_device_evdev_get_sysfs_path (device)) == 0)
++        return device;
+     }
+ 
+   return NULL;
+--
+cgit v0.9.2
+

Copied: clutter/repos/staging-x86_64/fix_buffer_age.patch (from rev 207405, clutter/trunk/fix_buffer_age.patch)
===================================================================
--- staging-x86_64/fix_buffer_age.patch	                        (rev 0)
+++ staging-x86_64/fix_buffer_age.patch	2014-03-08 16:54:51 UTC (rev 207406)
@@ -0,0 +1,34 @@
+From 6665f47d66a871b6e1a5f4200282f42da043a0e8 Mon Sep 17 00:00:00 2001
+From: Adel Gadllah <adel.gadllah at gmail.com>
+Date: Sun, 16 Feb 2014 21:07:43 +0000
+Subject: stage-cogl: Fix buffer_age code path
+
+Currently we where checking whether the damage_history list contains
+more or equal then buffer_age entries. This is wrong because we prepend
+our current clip to the list just before the check.
+
+Fix that to check whether we have more entries instead of more or equal.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=724788
+---
+diff --git a/clutter/cogl/clutter-stage-cogl.c b/clutter/cogl/clutter-stage-cogl.c
+index 86546b1..cff8444 100644
+--- a/clutter/cogl/clutter-stage-cogl.c
++++ b/clutter/cogl/clutter-stage-cogl.c
+@@ -483,11 +483,12 @@ clutter_stage_cogl_redraw (ClutterStageWindow *stage_window)
+ 
+         stage_cogl->damage_history = g_slist_prepend (stage_cogl->damage_history, current_damage);
+ 
+-        if (age != 0 && !stage_cogl->dirty_backbuffer && g_slist_length (stage_cogl->damage_history) >= age)
++        if (age != 0 && !stage_cogl->dirty_backbuffer && g_slist_length (stage_cogl->damage_history) > age)
+           {
+             int i = 0;
+             GSList *tmp = NULL;
+-            for (tmp = stage_cogl->damage_history; tmp; tmp = tmp->next)
++            /* We skip the first entry because it is the clip_region itself */
++            for (tmp = stage_cogl->damage_history->next; tmp; tmp = tmp->next)
+               {
+                 _clutter_util_rectangle_union (clip_region, tmp->data, clip_region);
+                 i++;
+--
+cgit v0.9.2

Copied: clutter/repos/staging-x86_64/stop_using_deprecated_libevdev_api.diff (from rev 207405, clutter/trunk/stop_using_deprecated_libevdev_api.diff)
===================================================================
--- staging-x86_64/stop_using_deprecated_libevdev_api.diff	                        (rev 0)
+++ staging-x86_64/stop_using_deprecated_libevdev_api.diff	2014-03-08 16:54:51 UTC (rev 207406)
@@ -0,0 +1,117 @@
+From 3cd9a70fea1ccf795419a1726c7c279b0aaf237e Mon Sep 17 00:00:00 2001
+From: Rui Matos <tiagomatos at gmail.com>
+Date: Tue, 19 Nov 2013 16:02:58 +0000
+Subject: device-manager-evdev: Stop using deprecated libevdev API
+
+Fixes compiler warnings with libevdev >= 0.4 and makes use of a new
+function to set the clock id instead of doing the ioctl directly.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=712816
+---
+diff --git a/README.in b/README.in
+index 0018869..0e73a42 100644
+--- a/README.in
++++ b/README.in
+@@ -40,7 +40,7 @@ When building the CEx100 backend, Clutter also depends on:
+ When building the evdev input backend, Clutter also depends on:
+ 
+   • xkbcommon
+-  • libevdev
++  • libevdev ≥ @LIBEVDEV_REQ_VERSION@
+ 
+ If you are building the API reference you will also need:
+ 
+diff --git a/clutter/evdev/clutter-device-manager-evdev.c b/clutter/evdev/clutter-device-manager-evdev.c
+index 38d707f..bc34c39 100644
+--- a/clutter/evdev/clutter-device-manager-evdev.c
++++ b/clutter/evdev/clutter-device-manager-evdev.c
+@@ -605,11 +605,11 @@ sync_source (ClutterEventSource *source)
+   const gchar *device_path;
+ 
+   /* We read a SYN_DROPPED, ignore it and sync the device */
+-  err = libevdev_next_event (source->dev, LIBEVDEV_READ_SYNC, &ev);
++  err = libevdev_next_event (source->dev, LIBEVDEV_READ_FLAG_SYNC, &ev);
+   while (err == 1)
+     {
+       dispatch_one_event (source, &ev);
+-      err = libevdev_next_event (source->dev, LIBEVDEV_READ_SYNC, &ev);
++      err = libevdev_next_event (source->dev, LIBEVDEV_READ_FLAG_SYNC, &ev);
+     }
+ 
+   if (err != -EAGAIN && CLUTTER_HAS_DEBUG (EVENT))
+@@ -664,7 +664,7 @@ clutter_event_dispatch (GSource     *g_source,
+   if (clutter_events_pending ())
+     goto queue_event;
+ 
+-  err = libevdev_next_event (source->dev, LIBEVDEV_READ_NORMAL, &ev);
++  err = libevdev_next_event (source->dev, LIBEVDEV_READ_FLAG_NORMAL, &ev);
+   while (err != -EAGAIN)
+     {
+       if (err == 1)
+@@ -677,7 +677,7 @@ clutter_event_dispatch (GSource     *g_source,
+ 	  goto out;
+ 	}
+ 
+-      err = libevdev_next_event (source->dev, LIBEVDEV_READ_NORMAL, &ev);
++      err = libevdev_next_event (source->dev, LIBEVDEV_READ_FLAG_NORMAL, &ev);
+     }
+ 
+  queue_event:
+@@ -725,7 +725,7 @@ clutter_event_source_new (ClutterInputDeviceEvdev *input_device)
+   GSource *source = g_source_new (&event_funcs, sizeof (ClutterEventSource));
+   ClutterEventSource *event_source = (ClutterEventSource *) source;
+   const gchar *node_path;
+-  gint fd, clkid;
++  gint fd;
+   GError *error;
+   ClutterInputDeviceType device_type;
+ 
+@@ -756,15 +756,13 @@ clutter_event_source_new (ClutterInputDeviceEvdev *input_device)
+ 	}
+     }
+ 
+-  /* Tell evdev to use the monotonic clock for its timestamps */
+-  clkid = CLOCK_MONOTONIC;
+-  ioctl (fd, EVIOCSCLOCKID, &clkid);
+-
+   /* setup the source */
+   event_source->device = input_device;
+   event_source->event_poll_fd.fd = fd;
+   event_source->event_poll_fd.events = G_IO_IN;
++
+   libevdev_new_from_fd (fd, &event_source->dev);
++  libevdev_set_clock_id (event_source->dev, CLOCK_MONOTONIC);
+ 
+   device_type = clutter_input_device_get_device_type (CLUTTER_INPUT_DEVICE (input_device));
+   if (device_type == CLUTTER_TOUCHPAD_DEVICE)
+diff --git a/configure.ac b/configure.ac
+index 0448ee4..47fce79 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -146,6 +146,7 @@ m4_define([uprof_req_version],          [0.3])
+ m4_define([gtk_doc_req_version],        [1.15])
+ m4_define([xcomposite_req_version],     [0.4])
+ m4_define([gdk_req_version],            [3.3.18])
++m4_define([libevdev_req_version],       [0.4])
+ 
+ AC_SUBST([GLIB_REQ_VERSION],       [glib_req_version])
+ AC_SUBST([COGL_REQ_VERSION],       [cogl_req_version])
+@@ -158,6 +159,7 @@ AC_SUBST([UPROF_REQ_VERSION],      [uprof_req_version])
+ AC_SUBST([GTK_DOC_REQ_VERSION],    [gtk_doc_req_version])
+ AC_SUBST([XCOMPOSITE_REQ_VERSION], [xcomposite_req_version])
+ AC_SUBST([GDK_REQ_VERSION],        [gdk_req_version])
++AC_SUBST([LIBEVDEV_REQ_VERSION],   [libevdev_req_version])
+ 
+ # Checks for typedefs, structures, and compiler characteristics.
+ AM_PATH_GLIB_2_0([glib_req_version],
+@@ -478,7 +480,7 @@ AS_IF([test "x$enable_evdev" = "xyes"],
+         AS_IF([test "x$have_evdev" = "xyes"],
+               [
+                 CLUTTER_INPUT_BACKENDS="$CLUTTER_INPUT_BACKENDS evdev"
+-                BACKEND_PC_FILES="$BACKEND_PC_FILES gudev-1.0 libevdev xkbcommon"
++                BACKEND_PC_FILES="$BACKEND_PC_FILES gudev-1.0 libevdev >= $LIBEVDEV_REQ_VERSION xkbcommon"
+                 experimental_input_backend="yes"
+                 AC_DEFINE([HAVE_EVDEV], [1], [Have evdev support for input handling])
+                 SUPPORT_EVDEV=1
+--
+cgit v0.9.2

Copied: clutter/repos/staging-x86_64/unref_devices_on_removal.diff (from rev 207405, clutter/trunk/unref_devices_on_removal.diff)
===================================================================
--- staging-x86_64/unref_devices_on_removal.diff	                        (rev 0)
+++ staging-x86_64/unref_devices_on_removal.diff	2014-03-08 16:54:51 UTC (rev 207406)
@@ -0,0 +1,22 @@
+From 7d8f72a60e4087a4d9e48d3f0e38b669b3717243 Mon Sep 17 00:00:00 2001
+From: Rui Matos <tiagomatos at gmail.com>
+Date: Thu, 21 Nov 2013 13:50:40 +0000
+Subject: device-manager-evdev: Unref devices on removal
+
+https://bugzilla.gnome.org/show_bug.cgi?id=712812
+---
+diff --git a/clutter/evdev/clutter-device-manager-evdev.c b/clutter/evdev/clutter-device-manager-evdev.c
+index 9e7be95..256fd0e 100644
+--- a/clutter/evdev/clutter-device-manager-evdev.c
++++ b/clutter/evdev/clutter-device-manager-evdev.c
+@@ -1046,6 +1046,8 @@ clutter_device_manager_evdev_remove_device (ClutterDeviceManager *manager,
+       clutter_event_source_free (source);
+       priv->event_sources = g_slist_remove (priv->event_sources, source);
+     }
++
++  g_object_unref (device);
+ }
+ 
+ static const GSList *
+--
+cgit v0.9.2




More information about the arch-commits mailing list