diff options
author | Richard Purdie <richard@openedhand.com> | 2006-12-20 00:00:03 +0000 |
---|---|---|
committer | Richard Purdie <richard@openedhand.com> | 2006-12-20 00:00:03 +0000 |
commit | f5b38f9db0cebb0c7c9d9d72fa98a4ff5241db20 (patch) | |
tree | 337089b8ad5015b9485099a263763c0c72cd3a99 /meta/classes/base.bbclass | |
parent | 50bbb7742c760360d1003e441e2a029bee3035df (diff) | |
download | openembedded-core-f5b38f9db0cebb0c7c9d9d72fa98a4ff5241db20.tar.gz openembedded-core-f5b38f9db0cebb0c7c9d9d72fa98a4ff5241db20.tar.bz2 openembedded-core-f5b38f9db0cebb0c7c9d9d72fa98a4ff5241db20.zip |
Remove DISTRO_TYPE, replacing with IMAGE_FEATURES. Documentation is in local.conf.sample
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@1053 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta/classes/base.bbclass')
-rw-r--r-- | meta/classes/base.bbclass | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass index e7725b7443..e08a2be2d2 100644 --- a/meta/classes/base.bbclass +++ b/meta/classes/base.bbclass @@ -41,12 +41,17 @@ def base_conditional(variable, checkvalue, truevalue, falsevalue, d): else: return falsevalue -def base_contains(variable, checkvalue, truevalue, falsevalue, d): - import bb - if bb.data.getVar(variable,d,1).find(checkvalue) != -1: - return truevalue - else: - return falsevalue +def base_contains(variable, checkvalues, truevalue, falsevalue, d): + import bb + matches = 0 + if type(checkvalues).__name__ == "str": + checkvalues = [checkvalues] + for value in checkvalues: + if bb.data.getVar(variable,d,1).find(value) != -1: + matches = matches + 1 + if matches == len(checkvalues): + return truevalue + return falsevalue def base_both_contain(variable1, variable2, checkvalue, d): import bb |