aboutsummaryrefslogtreecommitdiffstats
path: root/meta/classes/sanity.bbclass
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2011-11-09 15:00:01 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-11-10 11:35:32 +0000
commitb22831fd63164c4db9c0b72934d7d734a6585251 (patch)
treeedb6581a041190290855bf86714430515c9f235a /meta/classes/sanity.bbclass
parent07ded02ffd37b4fe60a6210dbf56490ea306f0b6 (diff)
downloadopenembedded-core-contrib-b22831fd63164c4db9c0b72934d7d734a6585251.tar.gz
Convert to use direct access to the data store (instead of bb.data.*Var*())
This is the result of running the following over the metadata: sed \ -e 's:bb.data.\(setVar([^,()]*,[^,()]*\), *\([^ )]*\) *):\2.\1):g' \ -e 's:bb.data.\(setVarFlag([^,()]*,[^,()]*,[^,()]*\), *\([^) ]*\) *):\2.\1):g' \ -e 's:bb.data.\(getVar([^,()]*\), *\([^(), ]*\) *,\([^)]*\)):\2.\1,\3):g' \ -e 's:bb.data.\(getVarFlag([^,()]*,[^,()]*\), *\([^(), ]*\) *,\([^)]*\)):\2.\1,\3):g' \ -e 's:bb.data.\(getVarFlag([^,()]*,[^,()]*\), *\([^() ]*\) *):\2.\1):g' \ -e 's:bb.data.\(getVar([^,()]*\), *\([^) ]*\) *):\2.\1):g' \ -i `grep -ril bb.data *` Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/sanity.bbclass')
-rw-r--r--meta/classes/sanity.bbclass10
1 files changed, 5 insertions, 5 deletions
diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
index 838448f33c..53b82d73e3 100644
--- a/meta/classes/sanity.bbclass
+++ b/meta/classes/sanity.bbclass
@@ -14,7 +14,7 @@ def raise_sanity_error(msg):
def check_conf_exists(fn, data):
bbpath = []
fn = bb.data.expand(fn, data)
- vbbpath = bb.data.getVar("BBPATH", data)
+ vbbpath = data.getVar("BBPATH")
if vbbpath:
bbpath += vbbpath.split(":")
for p in bbpath:
@@ -87,12 +87,12 @@ def check_connectivity(d):
# URI's to check can be set in the CONNECTIVITY_CHECK_URIS variable
# using the same syntax as for SRC_URI. If the variable is not set
# the check is skipped
- test_uris = (bb.data.getVar('CONNECTIVITY_CHECK_URIS', d, True) or "").split()
+ test_uris = (d.getVar('CONNECTIVITY_CHECK_URIS', True) or "").split()
retval = ""
# Only check connectivity if network enabled and the
# CONNECTIVITY_CHECK_URIS are set
- network_enabled = not bb.data.getVar('BB_NO_NETWORK', d, True)
+ network_enabled = not d.getVar('BB_NO_NETWORK', True)
check_enabled = len(test_uris)
# Take a copy of the data store and unset MIRRORS and PREMIRROS
data = bb.data.createCopy(d)
@@ -105,7 +105,7 @@ def check_connectivity(d):
except Exception:
# Allow the message to be configured so that users can be
# pointed to a support mechanism.
- msg = bb.data.getVar('CONNECTIVITY_CHECK_MSG', data, True) or ""
+ msg = data.getVar('CONNECTIVITY_CHECK_MSG', True) or ""
if len(msg) == 0:
msg = "Failed to fetch test data from the network. Please ensure your network is configured correctly.\n"
retval = msg
@@ -450,7 +450,7 @@ def check_sanity(e):
addhandler check_sanity_eventhandler
python check_sanity_eventhandler() {
- if bb.event.getName(e) == "ConfigParsed" and bb.data.getVar("BB_WORKERCONTEXT", e.data, True) != "1":
+ if bb.event.getName(e) == "ConfigParsed" and e.data.getVar("BB_WORKERCONTEXT", True) != "1":
check_sanity(e)
return