summaryrefslogtreecommitdiff
path: root/classes/recipe_sanity.bbclass
diff options
context:
space:
mode:
authorChris Larson <clarson@mvista.com>2009-06-19 12:32:21 -0700
committerChris Larson <clarson@mvista.com>2009-06-19 12:32:57 -0700
commitdf7ddd8feaeab6b39ee784a581dfd723d79e9b80 (patch)
tree6cc972684b2f5e8e4fb1152e50de5b57ba0cff2a /classes/recipe_sanity.bbclass
parent91cdbe63a724125d65d3ec7bf81d84cef16ec653 (diff)
recipe_sanity.bbclass: add checks for "bad" vars like RDEPENDS/RPROVIDES.
Signed-off-by: Chris Larson <clarson@mvista.com>
Diffstat (limited to 'classes/recipe_sanity.bbclass')
-rw-r--r--classes/recipe_sanity.bbclass8
1 files changed, 8 insertions, 0 deletions
diff --git a/classes/recipe_sanity.bbclass b/classes/recipe_sanity.bbclass
index 870a83f6c3..3b834c8223 100644
--- a/classes/recipe_sanity.bbclass
+++ b/classes/recipe_sanity.bbclass
@@ -2,6 +2,13 @@ def __note(msg, d):
import bb
bb.note("%s: recipe_sanity: %s" % (d.getVar("P", 1), msg))
+__recipe_sanity_badvars = "RDEPENDS RPROVIDES"
+def bad_vars(cfgdata, d):
+ for var in d.getVar("__recipe_sanity_badvars", 1).split():
+ val = d.getVar(var, 0)
+ if val and val != cfgdata.get(var):
+ __note("%s should not be set, but is set to '%s'" % (var, val), d)
+
__recipe_sanity_reqvars = "DESCRIPTION"
__recipe_sanity_reqdiffvars = "LICENSE"
def req_vars(cfgdata, d):
@@ -130,6 +137,7 @@ python do_recipe_sanity () {
can_remove_others(p, cfgdata, d)
var_renames_overwrite(cfgdata, d)
req_vars(cfgdata, d)
+ bad_vars(cfgdata, d)
}
do_recipe_sanity[nostamp] = "1"
#do_recipe_sanity[recrdeptask] = "do_recipe_sanity"