Patchwork [bitbake-devel,1.18,3/3] data_smart.py: add some internal bitbake variables to configuration hash

login
register
mail settings
Submitter Paul Eggleton
Date May 20, 2013, 3:20 p.m.
Message ID <f477bbdb42266bde95fdf4f43156edc08190cb98.1369063091.git.paul.eggleton@linux.intel.com>
Download mbox | patch
Permalink /patch/50167/
State New
Headers show

Comments

Paul Eggleton - May 20, 2013, 3:20 p.m.
From: Laurentiu Palcu <laurentiu.palcu@intel.com>

Take __BBTASKS, __BBHANDLERS and __BBANONFUNCS into account when
computing the configuration hash.

[YOCTO #4447]

(Bitbake master rev: 260ced7452405fc43ce3d9dd6798236aa07cc716)

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 bitbake/lib/bb/data_smart.py | 10 ++++++++++
 1 file changed, 10 insertions(+)

Patch

diff --git a/bitbake/lib/bb/data_smart.py b/bitbake/lib/bb/data_smart.py
index 5bf11e5..2fd8ccd 100644
--- a/bitbake/lib/bb/data_smart.py
+++ b/bitbake/lib/bb/data_smart.py
@@ -738,5 +738,15 @@  class DataSmart(MutableMapping):
             value = d.getVar(key, False) or ""
             data.update({key:value})
 
+        for key in ["__BBTASKS", "__BBANONFUNCS", "__BBHANDLERS"]:
+            bb_list = d.getVar(key, False) or []
+            bb_list.sort()
+            data.update({key:str(bb_list)})
+
+            if key == "__BBANONFUNCS":
+                for i in bb_list:
+                    value = d.getVar(i, True) or ""
+                    data.update({i:value})
+
         data_str = str([(k, data[k]) for k in sorted(data.keys())])
         return hashlib.md5(data_str).hexdigest()