1 |
commit: ee2c88b33e53671fce098e5cc4c96374a09e7991 |
2 |
Author: Sobhan Mohammadpour <sobhan <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Feb 23 12:00:00 2018 +0000 |
4 |
Commit: Sobhan Mohammadpour <sobhan <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Feb 23 12:00:00 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/gnome.git/commit/?id=ee2c88b3 |
7 |
|
8 |
dev-libs/glib: add an autotools based build |
9 |
|
10 |
Package-Manager: Portage-2.3.24, Repoman-2.3.6 |
11 |
Manifest-Sign-Key: 0x7DF238CF0AA182E1 |
12 |
|
13 |
...54.3-external-gdbus-codegen-for-autotools.patch | 116 ++++++++ |
14 |
dev-libs/glib/glib-2.54.3-r3.ebuild | 300 +++++++++++++++++++++ |
15 |
2 files changed, 416 insertions(+) |
16 |
|
17 |
diff --git a/dev-libs/glib/files/glib-2.54.3-external-gdbus-codegen-for-autotools.patch b/dev-libs/glib/files/glib-2.54.3-external-gdbus-codegen-for-autotools.patch |
18 |
new file mode 100644 |
19 |
index 00000000..45025b65 |
20 |
--- /dev/null |
21 |
+++ b/dev-libs/glib/files/glib-2.54.3-external-gdbus-codegen-for-autotools.patch |
22 |
@@ -0,0 +1,116 @@ |
23 |
+From 2e47d49bc91d83cd0abea4c1944bfca4336040fa Mon Sep 17 00:00:00 2001 |
24 |
+From: Sobhan Mohammadpour <sobhan@g.o> |
25 |
+Date: Fri, 23 Feb 2018 15:27:33 +0330 |
26 |
+Subject: [PATCH] glib-2.54.3-external-gdbus-codegen-for-autotools |
27 |
+ |
28 |
+--- |
29 |
+ configure.ac | 17 ++++++++--------- |
30 |
+ docs/reference/gio/Makefile.am | 1 - |
31 |
+ gio/Makefile.am | 2 +- |
32 |
+ gio/tests/Makefile.am | 6 ++---- |
33 |
+ gio/tests/gdbus-object-manager-example/Makefile.am | 8 +++----- |
34 |
+ 5 files changed, 14 insertions(+), 20 deletions(-) |
35 |
+ |
36 |
+diff --git a/configure.ac b/configure.ac |
37 |
+index 0457c90..07166c9 100644 |
38 |
+--- a/configure.ac |
39 |
++++ b/configure.ac |
40 |
+@@ -382,14 +382,14 @@ AC_SUBST(PERL_PATH) |
41 |
+ # option to specify python interpreter to use; this just sets $PYTHON, so that |
42 |
+ # we will fallback to reading $PYTHON if --with-python is not given, and |
43 |
+ # python.m4 will get the expected input |
44 |
+-AC_ARG_WITH(python, |
45 |
+- AS_HELP_STRING([--with-python=PATH], |
46 |
+- [Path to Python interpreter; searches $PATH if only a program name is given; if not given, searches for a few standard names such as "python3" or "python2"]), |
47 |
+- [PYTHON="$withval"], []) |
48 |
+-if test x"$PYTHON" = xyes; then |
49 |
+- AC_MSG_ERROR([--with-python option requires a path or program argument]) |
50 |
+-fi |
51 |
+-AM_PATH_PYTHON(2.7,,PYTHON="python2.7") |
52 |
++#AC_ARG_WITH(python, |
53 |
++# AS_HELP_STRING([--with-python=PATH], |
54 |
++# [Path to Python interpreter; searches $PATH if only a program name is given; if not given, searches for a few standard names such as "python3" or "python2"]), |
55 |
++# [PYTHON="$withval"], []) |
56 |
++#if test x"$PYTHON" = xyes; then |
57 |
++# AC_MSG_ERROR([--with-python option requires a path or program argument]) |
58 |
++#fi |
59 |
++#AM_PATH_PYTHON(2.7,,PYTHON="python2.7") |
60 |
+ |
61 |
+ |
62 |
+ dnl *********************** |
63 |
+@@ -3469,7 +3469,6 @@ gobject/glib-mkenums |
64 |
+ gobject/tests/Makefile |
65 |
+ gthread/Makefile |
66 |
+ gio/Makefile |
67 |
+-gio/gdbus-2.0/codegen/Makefile |
68 |
+ gio/gdbus-2.0/codegen/config.py |
69 |
+ gio/gnetworking.h |
70 |
+ gio/xdgmime/Makefile |
71 |
+diff --git a/docs/reference/gio/Makefile.am b/docs/reference/gio/Makefile.am |
72 |
+index 5741a3e..d38e768 100644 |
73 |
+--- a/docs/reference/gio/Makefile.am |
74 |
++++ b/docs/reference/gio/Makefile.am |
75 |
+@@ -177,7 +177,6 @@ man_MANS += \ |
76 |
+ gsettings.1 \ |
77 |
+ gresource.1 \ |
78 |
+ gdbus.1 \ |
79 |
+- gdbus-codegen.1 \ |
80 |
+ gio.1 \ |
81 |
+ $(NULL) |
82 |
+ |
83 |
+diff --git a/gio/Makefile.am b/gio/Makefile.am |
84 |
+index b2db995..53d7162 100644 |
85 |
+--- a/gio/Makefile.am |
86 |
++++ b/gio/Makefile.am |
87 |
+@@ -1,6 +1,6 @@ |
88 |
+ include $(top_srcdir)/glib.mk |
89 |
+ |
90 |
+-SUBDIRS = gdbus-2.0/codegen |
91 |
++SUBDIRS = |
92 |
+ |
93 |
+ if OS_UNIX |
94 |
+ if !OS_COCOA |
95 |
+diff --git a/gio/tests/Makefile.am b/gio/tests/Makefile.am |
96 |
+index acc1da4..7c51eab 100644 |
97 |
+--- a/gio/tests/Makefile.am |
98 |
++++ b/gio/tests/Makefile.am |
99 |
+@@ -460,10 +460,8 @@ gnotification_SOURCES = $(gdbus_sessionbus_sources) gnotifica |
100 |
+ |
101 |
+ BUILT_SOURCES += gdbus-test-codegen-generated.c gdbus-test-codegen-generated.h |
102 |
+ gdbus-test-codegen.o: gdbus-test-codegen-generated.h |
103 |
+-gdbus-test-codegen-generated.h: test-codegen.xml Makefile $(top_builddir)/gio/gdbus-2.0/codegen/gdbus-codegen |
104 |
+- $(AM_V_GEN) UNINSTALLED_GLIB_SRCDIR=$(top_srcdir) \ |
105 |
+- UNINSTALLED_GLIB_BUILDDIR=$(top_builddir) \ |
106 |
+- $(PYTHON) $(top_builddir)/gio/gdbus-2.0/codegen/gdbus-codegen \ |
107 |
++gdbus-test-codegen-generated.h: test-codegen.xml Makefile |
108 |
++ $(AM_V_GEN) gdbus-codegen \ |
109 |
+ --interface-prefix org.project. \ |
110 |
+ --generate-c-code gdbus-test-codegen-generated \ |
111 |
+ --c-generate-object-manager \ |
112 |
+diff --git a/gio/tests/gdbus-object-manager-example/Makefile.am b/gio/tests/gdbus-object-manager-example/Makefile.am |
113 |
+index 1d0464c..f390dca 100644 |
114 |
+--- a/gio/tests/gdbus-object-manager-example/Makefile.am |
115 |
++++ b/gio/tests/gdbus-object-manager-example/Makefile.am |
116 |
+@@ -11,10 +11,8 @@ GDBUS_GENERATED = \ |
117 |
+ gdbus-example-objectmanager-generated-org.gtk.GDBus.Example.ObjectManager.Cat.xml \ |
118 |
+ $(NULL) |
119 |
+ |
120 |
+-$(GDBUS_GENERATED) : gdbus-example-objectmanager.xml Makefile $(top_builddir)/gio/gdbus-2.0/codegen/gdbus-codegen |
121 |
+- $(AM_V_GEN) UNINSTALLED_GLIB_SRCDIR=$(top_srcdir) \ |
122 |
+- UNINSTALLED_GLIB_BUILDDIR=$(top_builddir) \ |
123 |
+- $(PYTHON) $(top_builddir)/gio/gdbus-2.0/codegen/gdbus-codegen \ |
124 |
++$(GDBUS_GENERATED) : gdbus-example-objectmanager.xml Makefile |
125 |
++ $(AM_V_GEN) gdbus-codegen \ |
126 |
+ --interface-prefix org.gtk.GDBus.Example.ObjectManager. \ |
127 |
+ --c-namespace Example \ |
128 |
+ --c-generate-object-manager \ |
129 |
+@@ -46,4 +44,4 @@ EXTRA_DIST += gdbus-example-objectmanager.xml |
130 |
+ |
131 |
+ CLEANFILES += $(GDBUS_GENERATED) |
132 |
+ |
133 |
+-check-TESTS: |
134 |
+\ No newline at end of file |
135 |
++check-TESTS: |
136 |
+-- |
137 |
+2.16.1 |
138 |
+ |
139 |
|
140 |
diff --git a/dev-libs/glib/glib-2.54.3-r3.ebuild b/dev-libs/glib/glib-2.54.3-r3.ebuild |
141 |
new file mode 100644 |
142 |
index 00000000..7c1b378c |
143 |
--- /dev/null |
144 |
+++ b/dev-libs/glib/glib-2.54.3-r3.ebuild |
145 |
@@ -0,0 +1,300 @@ |
146 |
+# Copyright 1999-2018 Gentoo Foundation |
147 |
+# Distributed under the terms of the GNU General Public License v2 |
148 |
+ |
149 |
+# Until bug #537330 glib is a reverse dependency of pkgconfig and, then |
150 |
+# adding new dependencies end up making stage3 to grow. Every addition needs |
151 |
+# then to be think very closely. |
152 |
+ |
153 |
+EAPI=6 |
154 |
+PYTHON_COMPAT=( python2_7 ) |
155 |
+# Completely useless with or without USE static-libs, people need to use |
156 |
+# pkg-config |
157 |
+GNOME2_LA_PUNT="yes" |
158 |
+ |
159 |
+inherit autotools bash-completion-r1 epunt-cxx flag-o-matic gnome2 libtool linux-info \ |
160 |
+ multilib multilib-minimal pax-utils python-r1 toolchain-funcs versionator virtualx |
161 |
+ |
162 |
+DESCRIPTION="The GLib library of C routines" |
163 |
+HOMEPAGE="https://www.gtk.org/" |
164 |
+SRC_URI="${SRC_URI} |
165 |
+ https://pkgconfig.freedesktop.org/releases/pkg-config-0.28.tar.gz" # pkg.m4 for eautoreconf |
166 |
+ |
167 |
+LICENSE="LGPL-2.1+" |
168 |
+SLOT="2" |
169 |
+IUSE="dbus debug fam kernel_linux +mime selinux static-libs systemtap test utils xattr" |
170 |
+REQUIRED_USE=" |
171 |
+ utils? ( ${PYTHON_REQUIRED_USE} ) |
172 |
+ test? ( ${PYTHON_REQUIRED_USE} ) |
173 |
+" |
174 |
+ |
175 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux" |
176 |
+ |
177 |
+# Added util-linux multilib dependency to have libmount support (which |
178 |
+# is always turned on on linux systems, unless explicitly disabled, but |
179 |
+# this ebuild does not do that anyway) (bug #599586) |
180 |
+ |
181 |
+RDEPEND=" |
182 |
+ !<dev-util/gdbus-codegen-${PV} |
183 |
+ >=dev-libs/libpcre-8.13:3[${MULTILIB_USEDEP},static-libs?] |
184 |
+ >=virtual/libiconv-0-r1[${MULTILIB_USEDEP}] |
185 |
+ >=virtual/libffi-3.0.13-r1[${MULTILIB_USEDEP}] |
186 |
+ >=virtual/libintl-0-r2[${MULTILIB_USEDEP}] |
187 |
+ >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] |
188 |
+ kernel_linux? ( sys-apps/util-linux[${MULTILIB_USEDEP}] ) |
189 |
+ selinux? ( >=sys-libs/libselinux-2.2.2-r5[${MULTILIB_USEDEP}] ) |
190 |
+ xattr? ( >=sys-apps/attr-2.4.47-r1[${MULTILIB_USEDEP}] ) |
191 |
+ fam? ( >=virtual/fam-0-r1[${MULTILIB_USEDEP}] ) |
192 |
+ utils? ( |
193 |
+ ${PYTHON_DEPS} |
194 |
+ >=dev-util/gdbus-codegen-${PV}[${PYTHON_USEDEP}] |
195 |
+ virtual/libelf:0= |
196 |
+ ) |
197 |
+" |
198 |
+DEPEND="${RDEPEND} |
199 |
+ app-text/docbook-xml-dtd:4.1.2 |
200 |
+ >=dev-libs/libxslt-1.0 |
201 |
+ >=sys-devel/gettext-0.11 |
202 |
+ >=dev-util/gtk-doc-am-1.20 |
203 |
+ systemtap? ( >=dev-util/systemtap-1.3 ) |
204 |
+ test? ( |
205 |
+ sys-devel/gdb |
206 |
+ ${PYTHON_DEPS} |
207 |
+ >=dev-util/gdbus-codegen-${PV}[${PYTHON_USEDEP}] |
208 |
+ >=sys-apps/dbus-1.2.14 ) |
209 |
+ !<dev-util/gtk-doc-1.15-r2 |
210 |
+" |
211 |
+PDEPEND="!<gnome-base/gvfs-1.6.4-r990 |
212 |
+ dbus? ( gnome-base/dconf ) |
213 |
+ mime? ( x11-misc/shared-mime-info ) |
214 |
+" |
215 |
+# shared-mime-info needed for gio/xdgmime, bug #409481 |
216 |
+# dconf is needed to be able to save settings, bug #498436 |
217 |
+# Earlier versions of gvfs do not work with glib |
218 |
+ |
219 |
+MULTILIB_CHOST_TOOLS=( |
220 |
+ /usr/bin/gio-querymodules$(get_exeext) |
221 |
+) |
222 |
+ |
223 |
+pkg_setup() { |
224 |
+ if use kernel_linux ; then |
225 |
+ CONFIG_CHECK="~INOTIFY_USER" |
226 |
+ if use test ; then |
227 |
+ CONFIG_CHECK="~IPV6" |
228 |
+ WARNING_IPV6="Your kernel needs IPV6 support for running some tests, skipping them." |
229 |
+ fi |
230 |
+ linux-info_pkg_setup |
231 |
+ fi |
232 |
+} |
233 |
+ |
234 |
+src_prepare() { |
235 |
+ # Prevent build failure in stage3 where pkgconfig is not available, bug #481056 |
236 |
+ mv -f "${WORKDIR}"/pkg-config-*/pkg.m4 "${S}"/m4macros/ || die |
237 |
+ |
238 |
+ if use test; then |
239 |
+ # Disable tests requiring dev-util/desktop-file-utils when not installed, bug #286629, upstream bug #629163 |
240 |
+ if ! has_version dev-util/desktop-file-utils ; then |
241 |
+ ewarn "Some tests will be skipped due dev-util/desktop-file-utils not being present on your system," |
242 |
+ ewarn "think on installing it to get these tests run." |
243 |
+ sed -i -e "/appinfo\/associations/d" gio/tests/appinfo.c || die |
244 |
+ sed -i -e "/g_test_add_func/d" gio/tests/desktop-app-info.c || die |
245 |
+ fi |
246 |
+ |
247 |
+ # gdesktopappinfo requires existing terminal (gnome-terminal or any |
248 |
+ # other), falling back to xterm if one doesn't exist |
249 |
+ if ! has_version x11-terms/xterm && ! has_version x11-terms/gnome-terminal ; then |
250 |
+ ewarn "Some tests will be skipped due to missing terminal program" |
251 |
+ sed -i -e "/appinfo\/launch/d" gio/tests/appinfo.c || die |
252 |
+ fi |
253 |
+ |
254 |
+ # https://bugzilla.gnome.org/show_bug.cgi?id=722604 |
255 |
+ sed -i -e "/timer\/stop/d" glib/tests/timer.c || die |
256 |
+ sed -i -e "/timer\/basic/d" glib/tests/timer.c || die |
257 |
+ |
258 |
+ ewarn "Tests for search-utils have been skipped" |
259 |
+ sed -i -e "/search-utils/d" glib/tests/Makefile.am || die |
260 |
+ else |
261 |
+ # Don't build tests, also prevents extra deps, bug #512022 |
262 |
+ sed -i -e 's/ tests//' {.,gio,glib}/Makefile.am || die |
263 |
+ fi |
264 |
+ |
265 |
+ # gdbus-codegen is a separate package |
266 |
+ eapply "${FILESDIR}"/${PN}-2.54.3-external-gdbus-codegen-for-autotools.patch |
267 |
+ |
268 |
+ # Leave python shebang alone - handled by python_replicate_script |
269 |
+ # We could call python_setup and give configure a valid --with-python |
270 |
+ # arg, but that would mean a build dep on python when USE=utils. |
271 |
+ sed -e '/${PYTHON}/d' \ |
272 |
+ -i glib/Makefile.{am,in} || die |
273 |
+ |
274 |
+ # Also needed to prevent cross-compile failures, see bug #267603 |
275 |
+ eautoreconf |
276 |
+ |
277 |
+ gnome2_src_prepare |
278 |
+ |
279 |
+ epunt_cxx |
280 |
+} |
281 |
+ |
282 |
+multilib_src_configure() { |
283 |
+ # Avoid circular depend with dev-util/pkgconfig and |
284 |
+ # native builds (cross-compiles won't need pkg-config |
285 |
+ # in the target ROOT to work here) |
286 |
+ if ! tc-is-cross-compiler && ! $(tc-getPKG_CONFIG) --version >& /dev/null; then |
287 |
+ if has_version sys-apps/dbus; then |
288 |
+ export DBUS1_CFLAGS="-I/usr/include/dbus-1.0 -I/usr/$(get_libdir)/dbus-1.0/include" |
289 |
+ export DBUS1_LIBS="-ldbus-1" |
290 |
+ fi |
291 |
+ export LIBFFI_CFLAGS="-I$(echo /usr/$(get_libdir)/libffi-*/include)" |
292 |
+ export LIBFFI_LIBS="-lffi" |
293 |
+ export PCRE_CFLAGS=" " # test -n "$PCRE_CFLAGS" needs to pass |
294 |
+ export PCRE_LIBS="-lpcre" |
295 |
+ fi |
296 |
+ |
297 |
+ # These configure tests don't work when cross-compiling. |
298 |
+ if tc-is-cross-compiler ; then |
299 |
+ # https://bugzilla.gnome.org/show_bug.cgi?id=756473 |
300 |
+ case ${CHOST} in |
301 |
+ hppa*|metag*) export glib_cv_stack_grows=yes ;; |
302 |
+ *) export glib_cv_stack_grows=no ;; |
303 |
+ esac |
304 |
+ # https://bugzilla.gnome.org/show_bug.cgi?id=756474 |
305 |
+ export glib_cv_uscore=no |
306 |
+ # https://bugzilla.gnome.org/show_bug.cgi?id=756475 |
307 |
+ export ac_cv_func_posix_get{pwuid,grgid}_r=yes |
308 |
+ fi |
309 |
+ |
310 |
+ local myconf |
311 |
+ |
312 |
+ case "${CHOST}" in |
313 |
+ *-mingw*) myconf="${myconf} --with-threads=win32" ;; |
314 |
+ *) myconf="${myconf} --with-threads=posix" ;; |
315 |
+ esac |
316 |
+ |
317 |
+ # libelf used only by the gresource bin |
318 |
+ ECONF_SOURCE="${S}" gnome2_src_configure ${myconf} \ |
319 |
+ $(usex debug --enable-debug=yes ' ') \ |
320 |
+ $(use_enable xattr) \ |
321 |
+ $(use_enable fam) \ |
322 |
+ $(use_enable kernel_linux libmount) \ |
323 |
+ $(use_enable selinux) \ |
324 |
+ $(use_enable static-libs static) \ |
325 |
+ $(use_enable systemtap dtrace) \ |
326 |
+ $(use_enable systemtap systemtap) \ |
327 |
+ $(multilib_native_use_enable utils libelf) \ |
328 |
+ --disable-compile-warnings \ |
329 |
+ --enable-man \ |
330 |
+ --with-pcre=system \ |
331 |
+ --with-xml-catalog="${EPREFIX}/etc/xml/catalog" |
332 |
+ |
333 |
+ if multilib_is_native_abi; then |
334 |
+ local d |
335 |
+ for d in glib gio gobject; do |
336 |
+ ln -s "${S}"/docs/reference/${d}/html docs/reference/${d}/html || die |
337 |
+ done |
338 |
+ fi |
339 |
+} |
340 |
+ |
341 |
+multilib_src_test() { |
342 |
+ export XDG_CONFIG_DIRS=/etc/xdg |
343 |
+ export XDG_DATA_DIRS=/usr/local/share:/usr/share |
344 |
+ export G_DBUS_COOKIE_SHA1_KEYRING_DIR="${T}/temp" |
345 |
+ export LC_TIME=C # bug #411967 |
346 |
+ unset GSETTINGS_BACKEND # bug #596380 |
347 |
+ python_setup |
348 |
+ |
349 |
+ # Related test is a bit nitpicking |
350 |
+ mkdir "$G_DBUS_COOKIE_SHA1_KEYRING_DIR" |
351 |
+ chmod 0700 "$G_DBUS_COOKIE_SHA1_KEYRING_DIR" |
352 |
+ |
353 |
+ # Hardened: gdb needs this, bug #338891 |
354 |
+ if host-is-pax ; then |
355 |
+ pax-mark -mr "${BUILD_DIR}"/tests/.libs/assert-msg-test \ |
356 |
+ || die "Hardened adjustment failed" |
357 |
+ fi |
358 |
+ |
359 |
+ # Need X for dbus-launch session X11 initialization |
360 |
+ virtx emake check |
361 |
+} |
362 |
+ |
363 |
+multilib_src_install() { |
364 |
+ gnome2_src_install completiondir="$(get_bashcompdir)" |
365 |
+ keepdir /usr/$(get_libdir)/gio/modules |
366 |
+} |
367 |
+ |
368 |
+multilib_src_install_all() { |
369 |
+ einstalldocs |
370 |
+ |
371 |
+ if use utils ; then |
372 |
+ python_replicate_script "${ED}"/usr/bin/gtester-report |
373 |
+ else |
374 |
+ rm "${ED}usr/bin/gtester-report" |
375 |
+ rm "${ED}usr/share/man/man1/gtester-report.1" |
376 |
+ fi |
377 |
+ |
378 |
+ # Do not install charset.alias even if generated, leave it to libiconv |
379 |
+ rm -f "${ED}/usr/lib/charset.alias" |
380 |
+ |
381 |
+ # Don't install gdb python macros, bug 291328 |
382 |
+ rm -rf "${ED}/usr/share/gdb/" "${ED}/usr/share/glib-2.0/gdb/" |
383 |
+} |
384 |
+ |
385 |
+pkg_preinst() { |
386 |
+ gnome2_pkg_preinst |
387 |
+ |
388 |
+ # Make gschemas.compiled belong to glib alone |
389 |
+ local cache="usr/share/glib-2.0/schemas/gschemas.compiled" |
390 |
+ |
391 |
+ if [[ -e ${EROOT}${cache} ]]; then |
392 |
+ cp "${EROOT}"${cache} "${ED}"/${cache} || die |
393 |
+ else |
394 |
+ touch "${ED}"/${cache} || die |
395 |
+ fi |
396 |
+ |
397 |
+ multilib_pkg_preinst() { |
398 |
+ # Make giomodule.cache belong to glib alone |
399 |
+ local cache="usr/$(get_libdir)/gio/modules/giomodule.cache" |
400 |
+ |
401 |
+ if [[ -e ${EROOT}${cache} ]]; then |
402 |
+ cp "${EROOT}"${cache} "${ED}"/${cache} || die |
403 |
+ else |
404 |
+ touch "${ED}"/${cache} || die |
405 |
+ fi |
406 |
+ } |
407 |
+ |
408 |
+ # Don't run the cache ownership when cross-compiling, as it would end up with an empty cache |
409 |
+ # file due to inability to create it and GIO might not look at any of the modules there |
410 |
+ if ! tc-is-cross-compiler ; then |
411 |
+ multilib_foreach_abi multilib_pkg_preinst |
412 |
+ fi |
413 |
+} |
414 |
+ |
415 |
+pkg_postinst() { |
416 |
+ # force (re)generation of gschemas.compiled |
417 |
+ GNOME2_ECLASS_GLIB_SCHEMAS="force" |
418 |
+ |
419 |
+ gnome2_pkg_postinst |
420 |
+ |
421 |
+ multilib_pkg_postinst() { |
422 |
+ gnome2_giomodule_cache_update \ |
423 |
+ || die "Update GIO modules cache failed (for ${ABI})" |
424 |
+ } |
425 |
+ if ! tc-is-cross-compiler ; then |
426 |
+ multilib_foreach_abi multilib_pkg_postinst |
427 |
+ else |
428 |
+ ewarn "Updating of GIO modules cache skipped due to cross-compilation." |
429 |
+ ewarn "You might want to run gio-querymodules manually on the target for" |
430 |
+ ewarn "your final image for performance reasons and re-run it when packages" |
431 |
+ ewarn "installing GIO modules get upgraded or added to the image." |
432 |
+ fi |
433 |
+} |
434 |
+ |
435 |
+pkg_postrm() { |
436 |
+ gnome2_pkg_postrm |
437 |
+ |
438 |
+ if [[ -z ${REPLACED_BY_VERSION} ]]; then |
439 |
+ multilib_pkg_postrm() { |
440 |
+ rm -f "${EROOT}"usr/$(get_libdir)/gio/modules/giomodule.cache |
441 |
+ } |
442 |
+ multilib_foreach_abi multilib_pkg_postrm |
443 |
+ rm -f "${EROOT}"usr/share/glib-2.0/schemas/gschemas.compiled |
444 |
+ fi |
445 |
+} |