diff options
author | Alexandre Rostovtsev <tetromino@gentoo.org> | 2011-12-17 01:55:23 +0000 |
---|---|---|
committer | Alexandre Rostovtsev <tetromino@gentoo.org> | 2011-12-17 01:55:23 +0000 |
commit | 63db92f945ed588501ccfb6860e1bf35319e6908 (patch) | |
tree | 3ccb9780e47a377ffde33f4600f6956cef61e7ff /x11-libs/gtksourceview | |
parent | Drop old. Don't inherit autotools as nothing uses that, bug #393913 wrt Agost... (diff) | |
download | gentoo-2-63db92f945ed588501ccfb6860e1bf35319e6908.tar.gz gentoo-2-63db92f945ed588501ccfb6860e1bf35319e6908.tar.bz2 gentoo-2-63db92f945ed588501ccfb6860e1bf35319e6908.zip |
Add patch from gtksourceview-3.x to not use G_CONST_RETURN in public headers (bug #394925, thanks to Rion for reporting).
(Portage version: 2.2.0_alpha80/cvs/Linux x86_64)
Diffstat (limited to 'x11-libs/gtksourceview')
-rw-r--r-- | x11-libs/gtksourceview/ChangeLog | 10 | ||||
-rw-r--r-- | x11-libs/gtksourceview/files/gtksourceview-2.10.5-G_CONST_RETURN.patch | 139 | ||||
-rw-r--r-- | x11-libs/gtksourceview/gtksourceview-2.10.5-r2.ebuild | 62 |
3 files changed, 210 insertions, 1 deletions
diff --git a/x11-libs/gtksourceview/ChangeLog b/x11-libs/gtksourceview/ChangeLog index 89b6a8de32d6..8ec360595296 100644 --- a/x11-libs/gtksourceview/ChangeLog +++ b/x11-libs/gtksourceview/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for x11-libs/gtksourceview # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/x11-libs/gtksourceview/ChangeLog,v 1.213 2011/11/22 00:15:49 pacho Exp $ +# $Header: /var/cvsroot/gentoo-x86/x11-libs/gtksourceview/ChangeLog,v 1.214 2011/12/17 01:55:23 tetromino Exp $ + +*gtksourceview-2.10.5-r2 (17 Dec 2011) + + 17 Dec 2011; Alexandre Rostovtsev <tetromino@gentoo.org> + +gtksourceview-2.10.5-r2.ebuild, + +files/gtksourceview-2.10.5-G_CONST_RETURN.patch: + Add patch from gtksourceview-3.x to not use G_CONST_RETURN in public headers + (bug #394925, thanks to Rion for reporting). 22 Nov 2011; Pacho Ramos <pacho@gentoo.org> gtksourceview-2.10.5-r1.ebuild, -gtksourceview-3.2.2.ebuild: diff --git a/x11-libs/gtksourceview/files/gtksourceview-2.10.5-G_CONST_RETURN.patch b/x11-libs/gtksourceview/files/gtksourceview-2.10.5-G_CONST_RETURN.patch new file mode 100644 index 000000000000..d42feacd3e3f --- /dev/null +++ b/x11-libs/gtksourceview/files/gtksourceview-2.10.5-G_CONST_RETURN.patch @@ -0,0 +1,139 @@ +From d27fec22c3f50bcd3c384256b8ad75d662033c7f Mon Sep 17 00:00:00 2001 +From: Ignacio Casal Quinteiro <icq@gnome.org> +Date: Sun, 13 Mar 2011 11:01:37 +0100 +Subject: [PATCH] Do not use G_CONST_RETURN anymore. This macro is going to be + deprecated. + +--- + gtksourceview/gtksourcelanguagemanager.c | 4 ++-- + gtksourceview/gtksourcelanguagemanager.h | 6 ++---- + gtksourceview/gtksourcestylescheme.c | 4 ++-- + gtksourceview/gtksourcestylescheme.h | 3 +-- + gtksourceview/gtksourcestyleschememanager.c | 4 ++-- + gtksourceview/gtksourcestyleschememanager.h | 6 ++---- + 6 files changed, 11 insertions(+), 16 deletions(-) + +diff --git a/gtksourceview/gtksourcelanguagemanager.c b/gtksourceview/gtksourcelanguagemanager.c +index b431e1f..31deba7 100644 +--- a/gtksourceview/gtksourcelanguagemanager.c ++++ b/gtksourceview/gtksourcelanguagemanager.c +@@ -275,7 +275,7 @@ gtk_source_language_manager_set_search_path (GtkSourceLanguageManager *lm, + * containg a list of language files directories. + * The array is owned by @lm and must not be modified. + */ +-G_CONST_RETURN gchar* G_CONST_RETURN * ++const gchar * const * + gtk_source_language_manager_get_search_path (GtkSourceLanguageManager *lm) + { + g_return_val_if_fail (GTK_IS_SOURCE_LANGUAGE_MANAGER (lm), NULL); +@@ -394,7 +394,7 @@ ensure_languages (GtkSourceLanguageManager *lm) + * no language is available. + * The array is owned by @lm and must not be modified. + */ +-G_CONST_RETURN gchar* G_CONST_RETURN * ++const gchar * const * + gtk_source_language_manager_get_language_ids (GtkSourceLanguageManager *lm) + { + g_return_val_if_fail (GTK_IS_SOURCE_LANGUAGE_MANAGER (lm), NULL); +diff --git a/gtksourceview/gtksourcelanguagemanager.h b/gtksourceview/gtksourcelanguagemanager.h +index ce234f5..de7a3aa 100644 +--- a/gtksourceview/gtksourcelanguagemanager.h ++++ b/gtksourceview/gtksourcelanguagemanager.h +@@ -63,14 +63,12 @@ GtkSourceLanguageManager *gtk_source_language_manager_new (void); + + GtkSourceLanguageManager *gtk_source_language_manager_get_default (void); + +-G_CONST_RETURN gchar* G_CONST_RETURN * +- gtk_source_language_manager_get_search_path (GtkSourceLanguageManager *lm); ++const gchar * const * gtk_source_language_manager_get_search_path (GtkSourceLanguageManager *lm); + + void gtk_source_language_manager_set_search_path (GtkSourceLanguageManager *lm, + gchar **dirs); + +-G_CONST_RETURN gchar* G_CONST_RETURN * +- gtk_source_language_manager_get_language_ids (GtkSourceLanguageManager *lm); ++const gchar * const * gtk_source_language_manager_get_language_ids (GtkSourceLanguageManager *lm); + + GtkSourceLanguage *gtk_source_language_manager_get_language (GtkSourceLanguageManager *lm, + const gchar *id); +diff --git a/gtksourceview/gtksourcestylescheme.c b/gtksourceview/gtksourcestylescheme.c +index 6b470e8..d9d41a3 100644 +--- a/gtksourceview/gtksourcestylescheme.c ++++ b/gtksourceview/gtksourcestylescheme.c +@@ -318,7 +318,7 @@ gtk_source_style_scheme_get_description (GtkSourceStyleScheme *scheme) + * + * Since: 2.0 + */ +-G_CONST_RETURN gchar* G_CONST_RETURN * ++const gchar * const * + gtk_source_style_scheme_get_authors (GtkSourceStyleScheme *scheme) + { + g_return_val_if_fail (GTK_IS_SOURCE_STYLE_SCHEME (scheme), NULL); +@@ -326,7 +326,7 @@ gtk_source_style_scheme_get_authors (GtkSourceStyleScheme *scheme) + if (scheme->priv->authors == NULL) + return NULL; + +- return (G_CONST_RETURN gchar* G_CONST_RETURN *)scheme->priv->authors->pdata; ++ return (const gchar * const *)scheme->priv->authors->pdata; + } + + /** +diff --git a/gtksourceview/gtksourcestylescheme.h b/gtksourceview/gtksourcestylescheme.h +index 501163c..fe74bd2 100644 +--- a/gtksourceview/gtksourcestylescheme.h ++++ b/gtksourceview/gtksourcestylescheme.h +@@ -62,8 +62,7 @@ const gchar *gtk_source_style_scheme_get_id (GtkSourceStyleS + const gchar *gtk_source_style_scheme_get_name (GtkSourceStyleScheme *scheme); + const gchar *gtk_source_style_scheme_get_description(GtkSourceStyleScheme *scheme); + +-G_CONST_RETURN gchar* G_CONST_RETURN * +- gtk_source_style_scheme_get_authors (GtkSourceStyleScheme *scheme); ++const gchar * const * gtk_source_style_scheme_get_authors (GtkSourceStyleScheme *scheme); + + const gchar *gtk_source_style_scheme_get_filename (GtkSourceStyleScheme *scheme); + +diff --git a/gtksourceview/gtksourcestyleschememanager.c b/gtksourceview/gtksourcestyleschememanager.c +index cba042f..eec5d45 100644 +--- a/gtksourceview/gtksourcestyleschememanager.c ++++ b/gtksourceview/gtksourcestyleschememanager.c +@@ -516,7 +516,7 @@ gtk_source_style_scheme_manager_prepend_search_path (GtkSourceStyleSchemeManager + * of string containing the search path. + * The array is owned by the @manager and must not be modified. + */ +-G_CONST_RETURN gchar* G_CONST_RETURN * ++const gchar * const * + gtk_source_style_scheme_manager_get_search_path (GtkSourceStyleSchemeManager *manager) + { + g_return_val_if_fail (GTK_IS_SOURCE_STYLE_SCHEME_MANAGER (manager), NULL); +@@ -555,7 +555,7 @@ gtk_source_style_scheme_manager_force_rescan (GtkSourceStyleSchemeManager *manag + * of string containing the ids of the available style schemes or %NULL if no + * style scheme is available. The array is owned by the @manager and must not be modified. + */ +-G_CONST_RETURN gchar* G_CONST_RETURN * ++const gchar * const * + gtk_source_style_scheme_manager_get_scheme_ids (GtkSourceStyleSchemeManager *manager) + { + g_return_val_if_fail (GTK_IS_SOURCE_STYLE_SCHEME_MANAGER (manager), NULL); +diff --git a/gtksourceview/gtksourcestyleschememanager.h b/gtksourceview/gtksourcestyleschememanager.h +index 6effc1c..456e8bf 100644 +--- a/gtksourceview/gtksourcestyleschememanager.h ++++ b/gtksourceview/gtksourcestyleschememanager.h +@@ -74,13 +74,11 @@ void gtk_source_style_scheme_manager_append_search_path (GtkSourceStyleSc + void gtk_source_style_scheme_manager_prepend_search_path (GtkSourceStyleSchemeManager *manager, + const gchar *path); + +-G_CONST_RETURN gchar* G_CONST_RETURN * +- gtk_source_style_scheme_manager_get_search_path (GtkSourceStyleSchemeManager *manager); ++const gchar * const * gtk_source_style_scheme_manager_get_search_path (GtkSourceStyleSchemeManager *manager); + + void gtk_source_style_scheme_manager_force_rescan (GtkSourceStyleSchemeManager *manager); + +-G_CONST_RETURN gchar* G_CONST_RETURN * +- gtk_source_style_scheme_manager_get_scheme_ids (GtkSourceStyleSchemeManager *manager); ++const gchar * const * gtk_source_style_scheme_manager_get_scheme_ids (GtkSourceStyleSchemeManager *manager); + + GtkSourceStyleScheme *gtk_source_style_scheme_manager_get_scheme (GtkSourceStyleSchemeManager *manager, + const gchar *scheme_id); +-- +1.7.8 + diff --git a/x11-libs/gtksourceview/gtksourceview-2.10.5-r2.ebuild b/x11-libs/gtksourceview/gtksourceview-2.10.5-r2.ebuild new file mode 100644 index 000000000000..61c22c4b2751 --- /dev/null +++ b/x11-libs/gtksourceview/gtksourceview-2.10.5-r2.ebuild @@ -0,0 +1,62 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/x11-libs/gtksourceview/gtksourceview-2.10.5-r2.ebuild,v 1.1 2011/12/17 01:55:23 tetromino Exp $ + +EAPI="4" +GCONF_DEBUG="no" +GNOME2_LA_PUNT="yes" +GNOME_TARBALL_SUFFIX="bz2" + +inherit eutils gnome2 virtualx + +DESCRIPTION="A text widget implementing syntax highlighting and other features" +HOMEPAGE="http://www.gnome.org/" + +LICENSE="GPL-2" +SLOT="2.0" +KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-freebsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x86-solaris" +IUSE="doc glade" + +# FIXME: We could avoid the glade conditional and dep completely if upstream +# would have a --with-glade-catalogdir that would allow to pass the system +# glade catalog dir, instead of needing gladeui-1.0.pc installed from dev-util/glade +RDEPEND=">=x11-libs/gtk+-2.12:2 + >=dev-libs/libxml2-2.5:2 + >=dev-libs/glib-2.14:2 + glade? ( >=dev-util/glade-3.2:3 ) + kernel_Darwin? ( x11-libs/ige-mac-integration )" +DEPEND="${RDEPEND} + >=sys-devel/gettext-0.17 + >=dev-util/intltool-0.40 + >=dev-util/pkgconfig-0.9 + doc? ( >=dev-util/gtk-doc-1.11 )" + +pkg_setup() { + DOCS="AUTHORS ChangeLog HACKING MAINTAINERS NEWS README" + G2CONF="${G2CONF} + $(use_enable glade glade-catalog)" +} + +src_prepare() { + gnome2_src_prepare + + # Skip broken test until upstream bug #621383 is solved + sed -i -e "/guess-language/d" tests/test-languagemanager.c || die + + # The same for another broken test, upstream bug #631214 + sed -i -e "/get-language/d" tests/test-languagemanager.c || die + + # Patch from 3.x for bug #394925 + epatch "${FILESDIR}/${P}-G_CONST_RETURN.patch" +} + +src_test() { + Xemake check || die "Test phase failed" +} + +src_install() { + gnome2_src_install + + insinto /usr/share/${PN}-2.0/language-specs + doins "${FILESDIR}"/2.0/gentoo.lang +} |