summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/cooker.py
diff options
context:
space:
mode:
authorChristopher Larson <chris_larson@mentor.com>2016-04-30 13:10:34 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-05-06 10:22:18 +0100
commitc6394a56f71028982006a821190c538c095a12f5 (patch)
treec9afb974d3ad7e627536d3f148ab41854dc1e04b /bitbake/lib/bb/cooker.py
parent94655584cba7543781a8d45fdacbb6027a38b07c (diff)
downloadpoky-c6394a56f71028982006a821190c538c095a12f5.tar.gz
bitbake: bb.{cooker, data}: only emit a var as python if 'func' is set
This avoids a common issue where PACKAGECONFIG is emitted as a function in bitbake -e when the 'python' flag exists. It isn't a python function unless both 'func' and 'python' are set. This aligns with the behavior of emit_func_python. (Bitbake rev: c5e45063cb3ae17bbe3304ea5e712bd76e686c4a) Signed-off-by: Christopher Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/cooker.py')
-rw-r--r--bitbake/lib/bb/cooker.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py
index 9b565fc37d..b2187d7d5f 100644
--- a/bitbake/lib/bb/cooker.py
+++ b/bitbake/lib/bb/cooker.py
@@ -656,7 +656,7 @@ class BBCooker:
656 # emit the metadata which isnt valid shell 656 # emit the metadata which isnt valid shell
657 data.expandKeys(envdata) 657 data.expandKeys(envdata)
658 for e in envdata.keys(): 658 for e in envdata.keys():
659 if data.getVarFlag( e, 'python', envdata ): 659 if envdata.getVarFlag(e, 'func', False) and envdata.getVarFlag(e, 'python', False):
660 logger.plain("\npython %s () {\n%s}\n", e, envdata.getVar(e, False)) 660 logger.plain("\npython %s () {\n%s}\n", e, envdata.getVar(e, False))
661 661
662 662