* [PATCH] gettext.bbclass, bitbake.conf: Append nls options to EXTRA_OECONF instead of +=
@ 2011-05-05 16:57 Khem Raj
2011-05-09 16:19 ` Saul Wold
0 siblings, 1 reply; 2+ messages in thread
From: Khem Raj @ 2011-05-05 16:57 UTC (permalink / raw)
To: OE core
Some recipes do not defined EXTRA_OECONF in such cases += drops
the --enable|--disable-nls options. In another case where recipe
defines EXTRA_OECONF instead of adding/appending to it then
--enable|--disable-nls options are lost from EXTRA_OECONF
We define EXTRA_OECONF = "" in bitbake.conf so the variable exists
always.
We use _append instead of += so the option is added at very end
and not lost.
We only return empty gettext dependencies if its a target recipe
in case when USE_NLS is not set because the native/cross/nativesdk recipes still
need the gettext dependencies
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
meta/classes/gettext.bbclass | 6 +++---
meta/conf/bitbake.conf | 2 +-
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/meta/classes/gettext.bbclass b/meta/classes/gettext.bbclass
index 6f79e5e..86b505b 100644
--- a/meta/classes/gettext.bbclass
+++ b/meta/classes/gettext.bbclass
@@ -1,7 +1,7 @@
def gettext_dependencies(d):
- if d.getVar('USE_NLS', True) == 'no':
+ if d.getVar('USE_NLS', True) == 'no' and not oe.utils.inherits(d, 'native', 'nativesdk', 'cross'):
return ""
- if bb.data.getVar('INHIBIT_DEFAULT_DEPS', d, True) and not oe.utils.inherits(d, 'cross-canadian'):
+ if d.getVar('INHIBIT_DEFAULT_DEPS', True) and not oe.utils.inherits(d, 'cross-canadian'):
return ""
return d.getVar('DEPENDS_GETTEXT', False)
@@ -14,4 +14,4 @@ def gettext_oeconf(d):
DEPENDS_GETTEXT = "virtual/gettext gettext-native"
BASEDEPENDS =+ "${@gettext_dependencies(d)}"
-EXTRA_OECONF += "${@gettext_oeconf(d)}"
+EXTRA_OECONF_append = " ${@gettext_oeconf(d)}"
diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
index a2b36bd..4a1bfa1 100644
--- a/meta/conf/bitbake.conf
+++ b/meta/conf/bitbake.conf
@@ -395,7 +395,7 @@ export BUILD_NM = "${BUILD_PREFIX}nm"
export MAKE = "make"
EXTRA_OEMAKE = "-e MAKEFLAGS="
-
+EXTRA_OECONF = ""
export LC_ALL = "C"
##################################################################
--
1.7.4.1
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] gettext.bbclass, bitbake.conf: Append nls options to EXTRA_OECONF instead of +=
2011-05-05 16:57 [PATCH] gettext.bbclass, bitbake.conf: Append nls options to EXTRA_OECONF instead of += Khem Raj
@ 2011-05-09 16:19 ` Saul Wold
0 siblings, 0 replies; 2+ messages in thread
From: Saul Wold @ 2011-05-09 16:19 UTC (permalink / raw)
To: Patches and discussions about the oe-core layer
On 05/05/2011 09:57 AM, Khem Raj wrote:
> Some recipes do not defined EXTRA_OECONF in such cases += drops
> the --enable|--disable-nls options. In another case where recipe
> defines EXTRA_OECONF instead of adding/appending to it then
> --enable|--disable-nls options are lost from EXTRA_OECONF
>
> We define EXTRA_OECONF = "" in bitbake.conf so the variable exists
> always.
>
> We use _append instead of += so the option is added at very end
> and not lost.
>
> We only return empty gettext dependencies if its a target recipe
> in case when USE_NLS is not set because the native/cross/nativesdk recipes still
> need the gettext dependencies
>
> Signed-off-by: Khem Raj<raj.khem@gmail.com>
> ---
> meta/classes/gettext.bbclass | 6 +++---
> meta/conf/bitbake.conf | 2 +-
> 2 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/meta/classes/gettext.bbclass b/meta/classes/gettext.bbclass
> index 6f79e5e..86b505b 100644
> --- a/meta/classes/gettext.bbclass
> +++ b/meta/classes/gettext.bbclass
> @@ -1,7 +1,7 @@
> def gettext_dependencies(d):
> - if d.getVar('USE_NLS', True) == 'no':
> + if d.getVar('USE_NLS', True) == 'no' and not oe.utils.inherits(d, 'native', 'nativesdk', 'cross'):
> return ""
> - if bb.data.getVar('INHIBIT_DEFAULT_DEPS', d, True) and not oe.utils.inherits(d, 'cross-canadian'):
> + if d.getVar('INHIBIT_DEFAULT_DEPS', True) and not oe.utils.inherits(d, 'cross-canadian'):
> return ""
> return d.getVar('DEPENDS_GETTEXT', False)
>
> @@ -14,4 +14,4 @@ def gettext_oeconf(d):
> DEPENDS_GETTEXT = "virtual/gettext gettext-native"
>
> BASEDEPENDS =+ "${@gettext_dependencies(d)}"
> -EXTRA_OECONF += "${@gettext_oeconf(d)}"
> +EXTRA_OECONF_append = " ${@gettext_oeconf(d)}"
> diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
> index a2b36bd..4a1bfa1 100644
> --- a/meta/conf/bitbake.conf
> +++ b/meta/conf/bitbake.conf
> @@ -395,7 +395,7 @@ export BUILD_NM = "${BUILD_PREFIX}nm"
>
> export MAKE = "make"
> EXTRA_OEMAKE = "-e MAKEFLAGS="
> -
> +EXTRA_OECONF = ""
> export LC_ALL = "C"
>
> ##################################################################
Pulled into oe-core
Thanks
Sau!
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-05-09 16:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-05 16:57 [PATCH] gettext.bbclass, bitbake.conf: Append nls options to EXTRA_OECONF instead of += Khem Raj
2011-05-09 16:19 ` Saul Wold
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox