summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Mende <angelos@gentoo.org>2011-04-27 07:18:47 +0000
committerChristoph Mende <angelos@gentoo.org>2011-04-27 07:18:47 +0000
commit75842650f688601b6e8b883b7f2c54c5e3194934 (patch)
tree7bbd032c80d3e29acb29a319fe2012970f81055d /media-sound/pulseaudio/files
parentVersion Bump, Cleaned old (diff)
downloadgentoo-2-75842650f688601b6e8b883b7f2c54c5e3194934.tar.gz
gentoo-2-75842650f688601b6e8b883b7f2c54c5e3194934.tar.bz2
gentoo-2-75842650f688601b6e8b883b7f2c54c5e3194934.zip
Fixed compilation against xcb-util-0.3.8 (bug #364965)
(Portage version: 2.2.0_alpha30/cvs/Linux x86_64)
Diffstat (limited to 'media-sound/pulseaudio/files')
-rw-r--r--media-sound/pulseaudio/files/pulseaudio-0.9.22-xcb-atom.patch83
1 files changed, 83 insertions, 0 deletions
diff --git a/media-sound/pulseaudio/files/pulseaudio-0.9.22-xcb-atom.patch b/media-sound/pulseaudio/files/pulseaudio-0.9.22-xcb-atom.patch
new file mode 100644
index 000000000000..b7f52f5898b8
--- /dev/null
+++ b/media-sound/pulseaudio/files/pulseaudio-0.9.22-xcb-atom.patch
@@ -0,0 +1,83 @@
+From 9cee2891e8ccd4b26b16449c120ac17e01aa1b36 Mon Sep 17 00:00:00 2001
+From: Maciej Grela <maciej.grela@gmail.com>
+Date: Tue, 29 Mar 2011 22:56:28 +0159
+Subject: [PATCH] x11: Fix build errors with newest xcb-util.
+
+The xcb_atom_get functions were removed from xcb-util. Changed these to
+xcb_intern_atom/xcb_intern_atom_reply. Also, STRING is now
+XCB_ATOM_STRING.
+---
+ src/pulsecore/x11prop.c | 26 +++++++++++++++++---------
+ 1 files changed, 17 insertions(+), 9 deletions(-)
+
+diff --git a/src/pulsecore/x11prop.c b/src/pulsecore/x11prop.c
+index 8df3278..99ea55d 100644
+--- a/src/pulsecore/x11prop.c
++++ b/src/pulsecore/x11prop.c
+@@ -49,28 +49,34 @@ static xcb_screen_t *screen_of_display(xcb_connection_t *xcb, int screen) {
+
+ void pa_x11_set_prop(xcb_connection_t *xcb, int screen, const char *name, const char *data) {
+ xcb_screen_t *xs;
+- xcb_atom_t a;
++ xcb_intern_atom_cookie_t cookie;
++ xcb_intern_atom_reply_t *reply;
+
+ pa_assert(xcb);
+ pa_assert(name);
+ pa_assert(data);
+
+ if ((xs = screen_of_display(xcb, screen))) {
+- a = xcb_atom_get(xcb, name);
+- xcb_change_property(xcb, XCB_PROP_MODE_REPLACE, xs->root, a, STRING, PA_XCB_FORMAT, (int) strlen(data), (const void*) data);
++ cookie = xcb_intern_atom(xcb, 0, strlen(name), name);
++ reply = xcb_intern_atom_reply(xcb, cookie, NULL);
++
++ xcb_change_property(xcb, XCB_PROP_MODE_REPLACE, xs->root, reply->atom, XCB_ATOM_STRING, PA_XCB_FORMAT, (int) strlen(data), (const void*) data);
+ }
+ }
+
+ void pa_x11_del_prop(xcb_connection_t *xcb, int screen, const char *name) {
+ xcb_screen_t *xs;
+- xcb_atom_t a;
++ xcb_intern_atom_cookie_t cookie;
++ xcb_intern_atom_reply_t *reply;
+
+ pa_assert(xcb);
+ pa_assert(name);
+
+ if ((xs = screen_of_display(xcb, screen))) {
+- a = xcb_atom_get(xcb, name);
+- xcb_delete_property(xcb, xs->root, a);
++ cookie = xcb_intern_atom(xcb, 0, strlen(name), name);
++ reply = xcb_intern_atom_reply(xcb, cookie, NULL);
++
++ xcb_delete_property(xcb, xs->root, reply->atom);
+ }
+ }
+
+@@ -80,7 +86,8 @@ char* pa_x11_get_prop(xcb_connection_t *xcb, int screen, const char *name, char
+ xcb_get_property_cookie_t req;
+ xcb_get_property_reply_t* prop = NULL;
+ xcb_screen_t *xs;
+- xcb_atom_t a;
++ xcb_intern_atom_cookie_t cookie;
++ xcb_intern_atom_reply_t *reply;
+
+ pa_assert(xcb);
+ pa_assert(name);
+@@ -98,9 +105,10 @@ char* pa_x11_get_prop(xcb_connection_t *xcb, int screen, const char *name, char
+ xs = screen_of_display(xcb, 0);
+
+ if (xs) {
+- a = xcb_atom_get(xcb, name);
++ cookie = xcb_intern_atom(xcb, 0, strlen(name), name);
++ reply = xcb_intern_atom_reply(xcb, cookie, NULL);
+
+- req = xcb_get_property(xcb, 0, xs->root, a, STRING, 0, (uint32_t)(l-1));
++ req = xcb_get_property(xcb, 0, xs->root, reply->atom, XCB_ATOM_STRING, 0, (uint32_t)(l-1));
+ prop = xcb_get_property_reply(xcb, req, NULL);
+
+ if (!prop)
+--
+1.7.4.1
+