summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/siggen.py
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2014-12-08 21:25:23 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-01-08 09:52:52 +0000
commit97d44bf526080c31188dfb5b0e0ffcd05a15455a (patch)
tree992c4630920fe14f7616d7c73c31b36921adfc75 /bitbake/lib/bb/siggen.py
parent26cd67e63a9451455def3be8ef03114dcac81ea5 (diff)
downloadpoky-97d44bf526080c31188dfb5b0e0ffcd05a15455a.tar.gz
bitbake: cache/fetch2/siggen: Ensure we track include history for file checksums
Currently, if you reference a file url, its checksum is included in the task hash, however if you change to a different file at a different location, perhaps taking advantage of the FILESPATH functionality, the system will not reparse the file in question and change its checksum to match the new file. To correctly handle this, the system not only needs to know if the existing file still exists or not, but also check the existance of every file it would have looked at when computing the original file. We already do this in the bitbake parsing code for class inclusion. This change uses the same technique to log the file list we looked at and if files in these locations exist when they previously did not, to invalidate and reparse the file. Since data stored in the cache is flattened text, we have to use a string form of the data and split on the ":" character which is ugly, but is an internal detail we can improve later if a better method is found. The cache version changes to trigger a reparse since the previous cache data is now incompatible. [YOCTO #7019] (Bitbake rev: 6c0706a28d72c591f1b75b6e3f3b645859387c7e) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/siggen.py')
-rw-r--r--bitbake/lib/bb/siggen.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/bitbake/lib/bb/siggen.py b/bitbake/lib/bb/siggen.py
index 0c77d72112..a0e70a8ee4 100644
--- a/bitbake/lib/bb/siggen.py
+++ b/bitbake/lib/bb/siggen.py
@@ -185,7 +185,8 @@ class SignatureGeneratorBasic(SignatureGenerator):
185 checksums = bb.fetch2.get_file_checksums(dataCache.file_checksums[fn][task], recipename) 185 checksums = bb.fetch2.get_file_checksums(dataCache.file_checksums[fn][task], recipename)
186 for (f,cs) in checksums: 186 for (f,cs) in checksums:
187 self.file_checksum_values[k][f] = cs 187 self.file_checksum_values[k][f] = cs
188 data = data + cs 188 if cs:
189 data = data + cs
189 190
190 taskdep = dataCache.task_deps[fn] 191 taskdep = dataCache.task_deps[fn]
191 if 'nostamp' in taskdep and task in taskdep['nostamp']: 192 if 'nostamp' in taskdep and task in taskdep['nostamp']: