1 |
commit: 7432d92b649634ba01819ffa74465a911c4dd628 |
2 |
Author: Alexandre Rostovtsev <tetromino <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Nov 3 03:36:02 2011 +0000 |
4 |
Commit: Alexandre Restovtsev <tetromino <AT> gmail <DOT> com> |
5 |
CommitDate: Thu Nov 3 04:06:20 2011 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/gnome.git;a=commit;h=7432d92b |
7 |
|
8 |
dev-libs/libpeas: fix g-i annotations + qa |
9 |
|
10 |
Add an upstream patch to change PeasPluginInfo return values from |
11 |
transfer full to transfer none; fixes crashes in python code that uses |
12 |
libpeas. |
13 |
|
14 |
Drop $(use_enable deprecated depracation): it had no effect (we were |
15 |
overriding it with --disable-depracation anyway, and there was no |
16 |
deprecated in IUSE), and disabling deprecations only makes sense for |
17 |
upstream libpeas developers, not for users. |
18 |
|
19 |
Port to EAPI4 and let gnome.eclass take care of maintainer mode. |
20 |
|
21 |
Drop KEYWORDS to match gx86. |
22 |
|
23 |
--- |
24 |
.../libpeas-1.2.0-PeasPluginInfo-annotation.patch | 57 ++++++++++++++++++++ |
25 |
...ibpeas-1.2.0.ebuild => libpeas-1.2.0-r1.ebuild} | 21 +++++--- |
26 |
dev-libs/libpeas/libpeas-9999.ebuild | 12 ++--- |
27 |
3 files changed, 75 insertions(+), 15 deletions(-) |
28 |
|
29 |
diff --git a/dev-libs/libpeas/files/libpeas-1.2.0-PeasPluginInfo-annotation.patch b/dev-libs/libpeas/files/libpeas-1.2.0-PeasPluginInfo-annotation.patch |
30 |
new file mode 100644 |
31 |
index 0000000..3a2e9b4 |
32 |
--- /dev/null |
33 |
+++ b/dev-libs/libpeas/files/libpeas-1.2.0-PeasPluginInfo-annotation.patch |
34 |
@@ -0,0 +1,57 @@ |
35 |
+From afa50c526ce1aab53eff3c3373a97180fc90abe2 Mon Sep 17 00:00:00 2001 |
36 |
+From: Garrett Regier <garrettregier@×××××.com> |
37 |
+Date: Thu, 29 Sep 2011 15:46:49 -0700 |
38 |
+Subject: [PATCH] Annotate PeasPluginInfo return values as transfer none |
39 |
+ |
40 |
+Otherwise GObject-Introspection says that it is transfer full. |
41 |
+ |
42 |
+https://bugzilla.gnome.org/show_bug.cgi?id=660524 |
43 |
+--- |
44 |
+ libpeas-gtk/peas-gtk-plugin-manager-view.c | 2 +- |
45 |
+ libpeas/peas-engine.c | 2 +- |
46 |
+ libpeas/peas-extension-base.c | 3 ++- |
47 |
+ 3 files changed, 4 insertions(+), 3 deletions(-) |
48 |
+ |
49 |
+diff --git a/libpeas-gtk/peas-gtk-plugin-manager-view.c b/libpeas-gtk/peas-gtk-plugin-manager-view.c |
50 |
+index 7eb7361..5f8f55f 100644 |
51 |
+--- a/libpeas-gtk/peas-gtk-plugin-manager-view.c |
52 |
++++ b/libpeas-gtk/peas-gtk-plugin-manager-view.c |
53 |
+@@ -952,7 +952,7 @@ peas_gtk_plugin_manager_view_set_selected_plugin (PeasGtkPluginManagerView *view |
54 |
+ * |
55 |
+ * Returns the currently selected plugin, or %NULL if a plugin is not selected. |
56 |
+ * |
57 |
+- * Returns: the selected plugin. |
58 |
++ * Returns: (transfer none): the selected plugin. |
59 |
+ */ |
60 |
+ PeasPluginInfo * |
61 |
+ peas_gtk_plugin_manager_view_get_selected_plugin (PeasGtkPluginManagerView *view) |
62 |
+diff --git a/libpeas/peas-engine.c b/libpeas/peas-engine.c |
63 |
+index 1adf4ff..7b57d56 100644 |
64 |
+--- a/libpeas/peas-engine.c |
65 |
++++ b/libpeas/peas-engine.c |
66 |
+@@ -733,7 +733,7 @@ compare_plugin_info_and_name (PeasPluginInfo *info, |
67 |
+ * Gets the #PeasPluginInfo corresponding with @plugin_name, |
68 |
+ * or %NULL if @plugin_name was not found. |
69 |
+ * |
70 |
+- * Returns: the #PeasPluginInfo corresponding with |
71 |
++ * Returns: (transfer none): the #PeasPluginInfo corresponding with |
72 |
+ * a given plugin module name. |
73 |
+ */ |
74 |
+ PeasPluginInfo * |
75 |
+diff --git a/libpeas/peas-extension-base.c b/libpeas/peas-extension-base.c |
76 |
+index 329a25f..7c4cba0 100644 |
77 |
+--- a/libpeas/peas-extension-base.c |
78 |
++++ b/libpeas/peas-extension-base.c |
79 |
+@@ -141,7 +141,8 @@ peas_extension_base_class_init (PeasExtensionBaseClass *klass) |
80 |
+ * |
81 |
+ * Get information relative to @extbase. |
82 |
+ * |
83 |
+- * Return value: the #PeasPluginInfo relative to the #PeasExtensionBase. |
84 |
++ * Return value: (transfer none): the #PeasPluginInfo relative |
85 |
++ * to the #PeasExtensionBase. |
86 |
+ */ |
87 |
+ PeasPluginInfo * |
88 |
+ peas_extension_base_get_plugin_info (PeasExtensionBase *extbase) |
89 |
+-- |
90 |
+1.7.7.2 |
91 |
+ |
92 |
|
93 |
diff --git a/dev-libs/libpeas/libpeas-1.2.0.ebuild b/dev-libs/libpeas/libpeas-1.2.0-r1.ebuild |
94 |
similarity index 84% |
95 |
rename from dev-libs/libpeas/libpeas-1.2.0.ebuild |
96 |
rename to dev-libs/libpeas/libpeas-1.2.0-r1.ebuild |
97 |
index 9582642..aba6158 100644 |
98 |
--- a/dev-libs/libpeas/libpeas-1.2.0.ebuild |
99 |
+++ b/dev-libs/libpeas/libpeas-1.2.0-r1.ebuild |
100 |
@@ -2,13 +2,12 @@ |
101 |
# Distributed under the terms of the GNU General Public License v2 |
102 |
# $Header: $ |
103 |
|
104 |
-EAPI="3" |
105 |
-GNOME_TARBALL_SUFFIX="xz" |
106 |
+EAPI="4" |
107 |
GCONF_DEBUG="no" |
108 |
GNOME2_LA_PUNT="yes" |
109 |
PYTHON_DEPEND="python? 2:2.5" |
110 |
|
111 |
-inherit gnome2 python virtualx |
112 |
+inherit eutils gnome2 python virtualx |
113 |
if [[ ${PV} = 9999 ]]; then |
114 |
inherit gnome2-live |
115 |
fi |
116 |
@@ -22,7 +21,7 @@ IUSE="doc gjs +gtk glade +python seed vala" |
117 |
if [[ ${PV} = 9999 ]]; then |
118 |
KEYWORDS="" |
119 |
else |
120 |
- KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" |
121 |
+ KEYWORDS="~amd64 ~x86" |
122 |
fi |
123 |
|
124 |
RDEPEND=">=dev-libs/glib-2.23.6:2 |
125 |
@@ -42,7 +41,6 @@ DOCS="AUTHORS ChangeLog NEWS README" |
126 |
|
127 |
pkg_setup() { |
128 |
G2CONF="${G2CONF} |
129 |
- $(use_enable deprecated deprecation) |
130 |
$(use_enable gjs) |
131 |
$(use_enable glade glade-catalog) |
132 |
$(use_enable gtk) |
133 |
@@ -51,12 +49,19 @@ pkg_setup() { |
134 |
$(use_enable vala) |
135 |
VALAC=$(type -P valac-0.12) |
136 |
--disable-deprecation |
137 |
- --disable-static |
138 |
- --disable-maintainer-mode" |
139 |
+ --disable-static" |
140 |
# Wtf, --disable-gcov, --enable-gcov=no, --enable-gcov, all enable gcov |
141 |
# What do we do about gdb, valgrind, gcov, etc? |
142 |
|
143 |
python_set_active_version 2 |
144 |
+ python_pkg_setup |
145 |
+} |
146 |
+ |
147 |
+src_prepare() { |
148 |
+ # Upstream patch to fix g-i annotations; prevents crashes |
149 |
+ epatch "${FILESDIR}/${P}-PeasPluginInfo-annotation.patch" |
150 |
+ |
151 |
+ gnome2_src_prepare |
152 |
} |
153 |
|
154 |
src_test() { |
155 |
@@ -66,5 +71,5 @@ src_test() { |
156 |
# >>> from gi.repository import Gtk |
157 |
# >>> Gtk.IconTheme.get_default().has_icon("gtk-about") |
158 |
# This should return True, it returns False for Xvfb |
159 |
- Xemake check || die |
160 |
+ Xemake check |
161 |
} |
162 |
|
163 |
diff --git a/dev-libs/libpeas/libpeas-9999.ebuild b/dev-libs/libpeas/libpeas-9999.ebuild |
164 |
index 9582642..84eb038 100644 |
165 |
--- a/dev-libs/libpeas/libpeas-9999.ebuild |
166 |
+++ b/dev-libs/libpeas/libpeas-9999.ebuild |
167 |
@@ -2,8 +2,7 @@ |
168 |
# Distributed under the terms of the GNU General Public License v2 |
169 |
# $Header: $ |
170 |
|
171 |
-EAPI="3" |
172 |
-GNOME_TARBALL_SUFFIX="xz" |
173 |
+EAPI="4" |
174 |
GCONF_DEBUG="no" |
175 |
GNOME2_LA_PUNT="yes" |
176 |
PYTHON_DEPEND="python? 2:2.5" |
177 |
@@ -22,7 +21,7 @@ IUSE="doc gjs +gtk glade +python seed vala" |
178 |
if [[ ${PV} = 9999 ]]; then |
179 |
KEYWORDS="" |
180 |
else |
181 |
- KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" |
182 |
+ KEYWORDS="~amd64 ~x86" |
183 |
fi |
184 |
|
185 |
RDEPEND=">=dev-libs/glib-2.23.6:2 |
186 |
@@ -42,7 +41,6 @@ DOCS="AUTHORS ChangeLog NEWS README" |
187 |
|
188 |
pkg_setup() { |
189 |
G2CONF="${G2CONF} |
190 |
- $(use_enable deprecated deprecation) |
191 |
$(use_enable gjs) |
192 |
$(use_enable glade glade-catalog) |
193 |
$(use_enable gtk) |
194 |
@@ -51,12 +49,12 @@ pkg_setup() { |
195 |
$(use_enable vala) |
196 |
VALAC=$(type -P valac-0.12) |
197 |
--disable-deprecation |
198 |
- --disable-static |
199 |
- --disable-maintainer-mode" |
200 |
+ --disable-static" |
201 |
# Wtf, --disable-gcov, --enable-gcov=no, --enable-gcov, all enable gcov |
202 |
# What do we do about gdb, valgrind, gcov, etc? |
203 |
|
204 |
python_set_active_version 2 |
205 |
+ python_pkg_setup |
206 |
} |
207 |
|
208 |
src_test() { |
209 |
@@ -66,5 +64,5 @@ src_test() { |
210 |
# >>> from gi.repository import Gtk |
211 |
# >>> Gtk.IconTheme.get_default().has_icon("gtk-about") |
212 |
# This should return True, it returns False for Xvfb |
213 |
- Xemake check || die |
214 |
+ Xemake check |
215 |
} |