1
0
mirror of https://git.yoctoproject.org/poky synced 2026-05-09 05:29:32 +00:00

oeqa/utils: make get_bb_var() more reliable

* Enable querying exported variables
* Use strip() to remove quotes so any internal quotes are not disturbed

(From OE-Core rev: 418cdf1ca37e06165ebaec86a0098d4750208539)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Paul Eggleton
2014-12-19 11:41:51 +00:00
committed by Richard Purdie
parent 15de188692
commit d7aec8c5f4
+2 -2
View File
@@ -138,9 +138,9 @@ def get_bb_var(var, target=None, postconfig=None):
val = None
bbenv = get_bb_env(target, postconfig=postconfig)
for line in bbenv.splitlines():
if line.startswith(var + "="):
if line.startswith(var + "=") or line.startswith("export " + var + "="):
val = line.split('=')[1]
val = val.replace('\"','')
val = val.strip('\"')
break
return val