summaryrefslogtreecommitdiffstats
path: root/meta/lib
diff options
context:
space:
mode:
authorRobert Yang <liezhi.yang@windriver.com>2016-09-12 01:32:07 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-09-14 22:22:07 +0100
commitb8e2bab119be251e3a3395dc55cf25b32504272c (patch)
tree112b9935eee0cf29390d04aec0b6b9938f15be5b /meta/lib
parent32b82672033013ad89b931aa1235415db699415e (diff)
downloadpoky-b8e2bab119be251e3a3395dc55cf25b32504272c.tar.gz
meta: cleanup d.getVar(var, 1)
(From OE-Core rev: 79fe476be233015c1c90e9c3fb4572267b5551d1) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib')
-rw-r--r--meta/lib/oe/utils.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/meta/lib/oe/utils.py b/meta/lib/oe/utils.py
index 19db540779..d6545b197d 100644
--- a/meta/lib/oe/utils.py
+++ b/meta/lib/oe/utils.py
@@ -23,13 +23,13 @@ def ifelse(condition, iftrue = True, iffalse = False):
23 return iffalse 23 return iffalse
24 24
25def conditional(variable, checkvalue, truevalue, falsevalue, d): 25def conditional(variable, checkvalue, truevalue, falsevalue, d):
26 if d.getVar(variable,1) == checkvalue: 26 if d.getVar(variable, True) == checkvalue:
27 return truevalue 27 return truevalue
28 else: 28 else:
29 return falsevalue 29 return falsevalue
30 30
31def less_or_equal(variable, checkvalue, truevalue, falsevalue, d): 31def less_or_equal(variable, checkvalue, truevalue, falsevalue, d):
32 if float(d.getVar(variable,1)) <= float(checkvalue): 32 if float(d.getVar(variable, True)) <= float(checkvalue):
33 return truevalue 33 return truevalue
34 else: 34 else:
35 return falsevalue 35 return falsevalue