Gentoo Archives: gentoo-dev

From: Gilles Dartiguelongue <eva@g.o>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] [PATCH 3/4] allow ebuild override of eclass generated econf
Date: Sun, 13 Jan 2013 19:06:52
Message-Id: 1358103944.23137.20.camel@kanae
In Reply to: [gentoo-dev] [PATCH 0/4] gnome2.eclass updates by Gilles Dartiguelongue
1 gnome2.eclass appends configure switches to user arguments.
2 Change logic so that it prepends values to G2CONF and pass extra args
3 of
4 gnome2_src_configure after G2CONF so that ebuilds can indeed override
5 eclass
6 settings.
7
8 ---
9 eclass/gnome2.eclass | 18 +++++++++---------
10 1 file changed, 9 insertions(+), 9 deletions(-)
11
12 diff --git a/eclass/gnome2.eclass b/eclass/gnome2.eclass
13 index e2540d1..750f20b 100644
14 --- a/eclass/gnome2.eclass
15 +++ b/eclass/gnome2.eclass
16 @@ -140,7 +140,7 @@ gnome2_src_configure() {
17 # Update the GNOME configuration options
18 if [[ ${GCONF_DEBUG} != 'no' ]] ; then
19 if use debug ; then
20 - G2CONF="${G2CONF} --enable-debug=yes"
21 + G2CONF="--enable-debug=yes ${G2CONF}"
22 fi
23 fi
24
25 @@ -153,44 +153,44 @@ gnome2_src_configure() {
26 # Preserve old behavior for older EAPI.
27 if grep -q "enable-gtk-doc" ${ECONF_SOURCE:-.}/configure ; then
28 if has ${EAPI:-0} 0 1 2 3 4 && in_iuse doc ; then
29 - G2CONF="${G2CONF} $(use_enable doc gtk-doc)"
30 + G2CONF="$(use_enable doc gtk-doc) ${G2CONF}"
31 else
32 - G2CONF="${G2CONF} --disable-gtk-doc"
33 + G2CONF="--disable-gtk-doc ${G2CONF}"
34 fi
35 fi
36
37 # Pass --disable-maintainer-mode when needed
38 if grep -q "^[[:space:]]*AM_MAINTAINER_MODE(\[enable\])" \
39 ${ECONF_SOURCE:-.}/configure.*; then
40 - G2CONF="${G2CONF} --disable-maintainer-mode"
41 + G2CONF="--disable-maintainer-mode ${G2CONF}"
42 fi
43
44 # Pass --disable-scrollkeeper when possible
45 if grep -q "disable-scrollkeeper" ${ECONF_SOURCE:-.}/configure; then
46 - G2CONF="${G2CONF} --disable-scrollkeeper"
47 + G2CONF="--disable-scrollkeeper ${G2CONF}"
48 fi
49
50 # Pass --disable-silent-rules when possible (not needed for eapi5),
51 bug #429308
52 if has ${EAPI:-0} 0 1 2 3 4; then
53 if grep -q "disable-silent-rules" ${ECONF_SOURCE:-.}/configure; then
54 - G2CONF="${G2CONF} --disable-silent-rules"
55 + G2CONF="--disable-silent-rules ${G2CONF}"
56 fi
57 fi
58
59 # Pass --disable-schemas-install when possible
60 if grep -q "disable-schemas-install" ${ECONF_SOURCE:-.}/configure;
61 then
62 - G2CONF="${G2CONF} --disable-schemas-install"
63 + G2CONF="--disable-schemas-install ${G2CONF}"
64 fi
65
66 # Pass --disable-schemas-compile when possible
67 if grep -q "disable-schemas-compile" ${ECONF_SOURCE:-.}/configure;
68 then
69 - G2CONF="${G2CONF} --disable-schemas-compile"
70 + G2CONF="--disable-schemas-compile ${G2CONF}"
71 fi
72
73 # Avoid sandbox violations caused by gnome-vfs (bug #128289 and
74 #345659)
75 addwrite "$(unset HOME; echo ~)/.gnome2"
76
77 - econf "$@" ${G2CONF}
78 + econf ${G2CONF} "$@"
79 }
80
81 # @FUNCTION: gnome2_src_compile
82 --
83 1.8.1

Attachments

File name MIME type
signature.asc application/pgp-signature