summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSaleem Abdulrasool <compnerd@gentoo.org>2008-04-22 02:54:55 +0000
committerSaleem Abdulrasool <compnerd@gentoo.org>2008-04-22 02:54:55 +0000
commitcc734f5238d8095fc670352b59342db317bea1e3 (patch)
treee98ef9522045e9bbf8783666e5516ca5e7ee6902 /dev-libs/dbus-glib
parentRe-added files/gdesklets-core-0.36_beta-linguas.patch (diff)
downloadgentoo-2-cc734f5238d8095fc670352b59342db317bea1e3.tar.gz
gentoo-2-cc734f5238d8095fc670352b59342db317bea1e3.tar.bz2
gentoo-2-cc734f5238d8095fc670352b59342db317bea1e3.zip
add namespace support
(Portage version: 2.1.5_rc2)
Diffstat (limited to 'dev-libs/dbus-glib')
-rw-r--r--dev-libs/dbus-glib/ChangeLog8
-rw-r--r--dev-libs/dbus-glib/dbus-glib-0.74-r1.ebuild62
-rw-r--r--dev-libs/dbus-glib/files/dbus-glib-0.73-namespaces.patch81
3 files changed, 150 insertions, 1 deletions
diff --git a/dev-libs/dbus-glib/ChangeLog b/dev-libs/dbus-glib/ChangeLog
index 52f4b407f213..e7082c52efed 100644
--- a/dev-libs/dbus-glib/ChangeLog
+++ b/dev-libs/dbus-glib/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for dev-libs/dbus-glib
# Copyright 2000-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-libs/dbus-glib/ChangeLog,v 1.35 2008/02/29 05:38:12 jer Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/dbus-glib/ChangeLog,v 1.36 2008/04/22 02:54:54 compnerd Exp $
+
+*dbus-glib-0.74-r1 (22 Apr 2008)
+
+ 22 Apr 2008; Saleem Abdulrasool <compnerd@gentoo.org>
+ +files/dbus-glib-0.73-namespaces.patch, +dbus-glib-0.74-r1.ebuild:
+ Add patch for namespace support in dbus-binding-tool
29 Feb 2008; Jeroen Roovers <jer@gentoo.org> dbus-glib-0.74.ebuild:
Stable for HPPA (bug #208917).
diff --git a/dev-libs/dbus-glib/dbus-glib-0.74-r1.ebuild b/dev-libs/dbus-glib/dbus-glib-0.74-r1.ebuild
new file mode 100644
index 000000000000..da467623327c
--- /dev/null
+++ b/dev-libs/dbus-glib/dbus-glib-0.74-r1.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/dbus-glib/dbus-glib-0.74-r1.ebuild,v 1.1 2008/04/22 02:54:54 compnerd Exp $
+
+inherit eutils multilib autotools
+
+DESCRIPTION="D-Bus bindings for glib"
+HOMEPAGE="http://dbus.freedesktop.org/"
+SRC_URI="http://dbus.freedesktop.org/releases/${PN}/${P}.tar.gz"
+
+LICENSE="|| ( GPL-2 AFL-2.1 )"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
+IUSE="doc selinux debug"
+
+RDEPEND=">=sys-apps/dbus-0.94
+ >=dev-libs/glib-2.6
+ selinux? ( sys-libs/libselinux )
+ >=dev-libs/libxml2-2.6.21"
+ # expat code now sucks.. libxml2 is the default
+DEPEND="${RDEPEND}
+ dev-util/pkgconfig
+ doc? ( app-doc/doxygen app-text/xmlto )"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch "${FILESDIR}"/${PN}-introspection.patch
+ epatch "${FILESDIR}/${PN}-0.73-namespaces.patch"
+}
+
+src_compile() {
+ local myconf=""
+
+ econf \
+ $(use_enable selinux) \
+ $(use_enable debug verbose-mode) \
+ $(use_enable debug checks) \
+ $(use_enable debug asserts) \
+ --with-xml=libxml \
+ --with-system-pid-file=/var/run/dbus.pid \
+ --with-system-socket=/var/run/dbus/system_bus_socket \
+ --with-session-socket-dir=/tmp \
+ --with-dbus-user=messagebus \
+ --localstatedir=/var \
+ $(use_enable doc doxygen-docs) \
+ --disable-xml-docs \
+ ${myconf} \
+ || die "econf failed"
+
+ # after the compile, it uses a selinuxfs interface to
+ # check if the SELinux policy has the right support
+ use selinux && addwrite /selinux/access
+
+ emake || die "make failed"
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die "make install failed"
+
+ dodoc AUTHORS ChangeLog HACKING NEWS README
+}
diff --git a/dev-libs/dbus-glib/files/dbus-glib-0.73-namespaces.patch b/dev-libs/dbus-glib/files/dbus-glib-0.73-namespaces.patch
new file mode 100644
index 000000000000..53bc4eb33e46
--- /dev/null
+++ b/dev-libs/dbus-glib/files/dbus-glib-0.73-namespaces.patch
@@ -0,0 +1,81 @@
+--- dbus/dbus-gparser.c 2006-09-27 08:27:24.000000000 -0400
++++ dbus/dbus-gparser.c 2008-03-13 08:54:14.000000000 -0400
+@@ -128,13 +128,17 @@ locate_attributes (const char *element_
+
+ if (!found)
+ {
+- g_set_error (error,
+- G_MARKUP_ERROR,
+- G_MARKUP_ERROR_PARSE,
+- _("Attribute \"%s\" is invalid on <%s> element in this context"),
+- attribute_names[i], element_name);
+- retval = FALSE;
+- goto out;
++ /* We want to passthrough namespaced XML nodes that we don't know anything about. */
++ if (strchr (attribute_names[i], ':') == NULL)
++ {
++ g_set_error (error,
++ G_MARKUP_ERROR,
++ G_MARKUP_ERROR_PARSE,
++ _("Attribute \"%s\" is invalid on <%s> element in this context"),
++ attribute_names[i], element_name);
++ retval = FALSE;
++ goto out;
++ }
+ }
+
+ ++i;
+@@ -177,6 +181,7 @@ struct Parser
+ PropertyInfo *property;
+ ArgInfo *arg;
+ gboolean in_annotation;
++ guint unknown_namespaced_depth;
+ };
+
+ Parser*
+@@ -791,10 +796,14 @@ parser_start_element (Parser *parse
+ }
+ else
+ {
+- g_set_error (error, G_MARKUP_ERROR,
+- G_MARKUP_ERROR_PARSE,
+- _("Element <%s> not recognized"),
+- element_name);
++ if (strchr (element_name, ':') != NULL)
++ /* Passthrough XML-namespaced nodes */
++ parser->unknown_namespaced_depth += 1;
++ else if (parser->unknown_namespaced_depth == 0)
++ g_set_error (error, G_MARKUP_ERROR,
++ G_MARKUP_ERROR_PARSE,
++ _("Element <%s> not recognized"),
++ element_name);
+ }
+
+ return TRUE;
+@@ -844,6 +853,15 @@ parser_end_element (Parser *parser,
+ if (parser->node_stack == NULL)
+ parser->result = top; /* We are done, store the result */
+ }
++ else if (strchr (element_name, ':') != NULL)
++ {
++ /* Passthrough XML-namespaced nodes */
++ parser->unknown_namespaced_depth -= 1;
++ }
++ else if (parser->unknown_namespaced_depth > 0)
++ {
++ /* pass through unknown elements underneath a namespace */
++ }
+ else
+ g_assert_not_reached (); /* should have had an error on start_element */
+
+--- dbus/dbus-glib-tool.c 2008-03-13 08:31:21.000000000 -0400
++++ dbus/dbus-glib-tool.c 2008-03-13 08:32:15.000000000 -0400
+@@ -414,7 +414,7 @@ main (int argc, char **argv)
+ &error);
+ if (node == NULL)
+ {
+- lose_gerror (_("Unable to load \"%s\""), error);
++ lose (_("Unable to load \"%s\": %s"), filename, error->message);
+ }
+ else
+ {