summaryrefslogtreecommitdiffstats
path: root/meta/lib
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@intel.com>2013-03-09 10:33:25 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-03-10 04:36:52 +0000
commit0aad8decf0eb17b90153225493f28835d24f043a (patch)
tree83c479e4efca36caf773132e3e63f22825540f62 /meta/lib
parent9b4e10acc53d22ee9a6bb566c1d665e45f4407cc (diff)
downloadpoky-0aad8decf0eb17b90153225493f28835d24f043a.tar.gz
base.bbclass: don't backfill features that already exist
It's too easy to cause rebuilds because the DISTRO_FEATURES have changed in meaningless ways (such as re-ordering or duplicate items). Help stop this by checking if the feature to be back-filled is already present. (From OE-Core rev: 63c7192119d54b92d908441109ed4e4fff761cba) 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.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/meta/lib/oe/utils.py b/meta/lib/oe/utils.py
index 8d3efe440c..b269f32277 100644
--- a/meta/lib/oe/utils.py
+++ b/meta/lib/oe/utils.py
@@ -96,16 +96,14 @@ def features_backfill(var,d):
96 # disturbing distributions that have already set DISTRO_FEATURES. 96 # disturbing distributions that have already set DISTRO_FEATURES.
97 # Distributions wanting to elide a value in DISTRO_FEATURES_BACKFILL should 97 # Distributions wanting to elide a value in DISTRO_FEATURES_BACKFILL should
98 # add the feature to DISTRO_FEATURES_BACKFILL_CONSIDERED 98 # add the feature to DISTRO_FEATURES_BACKFILL_CONSIDERED
99 99 features = (d.getVar(var, True) or "").split()
100 backfill = (d.getVar(var+"_BACKFILL", True) or "").split() 100 backfill = (d.getVar(var+"_BACKFILL", True) or "").split()
101 considered = (d.getVar(var+"_BACKFILL_CONSIDERED", True) or "").split() 101 considered = (d.getVar(var+"_BACKFILL_CONSIDERED", True) or "").split()
102 102
103 addfeatures = [] 103 addfeatures = []
104 for feature in backfill: 104 for feature in backfill:
105 if feature not in considered: 105 if feature not in features and feature not in considered:
106 addfeatures.append(feature) 106 addfeatures.append(feature)
107 107
108 if addfeatures: 108 if addfeatures:
109 return " %s" % (" ".join(addfeatures)) 109 d.appendVar(var, " " + " ".join(addfeatures))
110 else:
111 return ""