summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2017-04-20 14:20:29 +1200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-04-20 07:58:52 +0100
commitb3d2c9917c5fd8278878328794daa107ddf79b64 (patch)
tree78418377f65998fc41f151f25f8ed2910ea56914
parentb4da94a368c6c44c6e5b6e6e9a1e041ed84b4554 (diff)
downloadbitbake-contrib-b3d2c9917c5fd8278878328794daa107ddf79b64.tar.gz
lib/bb/command: fix overrides in remote datastores where there is no default
If you have, for example, no value set for a variable VARIABLE and a then VARIABLE_pn-something = "value" and then you parse something.bb, you expect getVar('VARIABLE') on the resulting datastore to return "value", but the code here assumed that if the variable wasn't set without overrides then we didn't need to return the overridedata and thus we didn't get the overridden value. In OE this affected the ability to get RECIPE_MAINTAINER for a recipe in a script using tinfoil (since this is only set from an inc file with _pn- overrides for each recipe, and no default is set). Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--lib/bb/command.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/bb/command.py b/lib/bb/command.py
index 390d4f1de..ab51d8e6c 100644
--- a/lib/bb/command.py
+++ b/lib/bb/command.py
@@ -479,6 +479,9 @@ class CommandsSync:
'_connector_overrides': overridedata}
else:
value['_connector_overrides'] = overridedata
+ else:
+ value = {}
+ value['_connector_overrides'] = overridedata
return value
dataStoreConnectorFindVar.readonly = True