summaryrefslogtreecommitdiff
path: root/poky/bitbake/lib/bb/data.py
diff options
context:
space:
mode:
authorJason M. Bills <jason.m.bills@linux.intel.com>2020-12-08 00:38:17 +0300
committerJason M. Bills <jason.m.bills@linux.intel.com>2020-12-08 00:38:17 +0300
commit8d6ae7f2a817751fad151168fa10ce28ee0869d8 (patch)
tree281032f7ec07c41589aa094bd165cc2a98f2d3a7 /poky/bitbake/lib/bb/data.py
parentc16fb8893b19075db4bcf3b5bf33c1db8c3ca2bd (diff)
parent5da3c2284560a7e08ffafd03c5b5ba44a3242228 (diff)
downloadopenbmc-8d6ae7f2a817751fad151168fa10ce28ee0869d8.tar.xz
Merge tag '0.26' of ssh://git-amr-1.devtools.intel.com:29418/openbmc-openbmc into update
Diffstat (limited to 'poky/bitbake/lib/bb/data.py')
-rw-r--r--poky/bitbake/lib/bb/data.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/poky/bitbake/lib/bb/data.py b/poky/bitbake/lib/bb/data.py
index b0683c518..97022853c 100644
--- a/poky/bitbake/lib/bb/data.py
+++ b/poky/bitbake/lib/bb/data.py
@@ -161,6 +161,12 @@ def emit_var(var, o=sys.__stdout__, d = init(), all=False):
return True
if func:
+ # Write a comment indicating where the shell function came from (line number and filename) to make it easier
+ # for the user to diagnose task failures. This comment is also used by build.py to determine the metadata
+ # location of shell functions.
+ o.write("# line: {0}, file: {1}\n".format(
+ d.getVarFlag(var, "lineno", False),
+ d.getVarFlag(var, "filename", False)))
# NOTE: should probably check for unbalanced {} within the var
val = val.rstrip('\n')
o.write("%s() {\n%s\n}\n" % (varExpanded, val))