summaryrefslogtreecommitdiffstats
path: root/bitbake/lib
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2016-04-02 17:10:48 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-04-03 15:53:44 +0100
commit3e1b5e0685eba0f56ad82f49e28cf8a173affad8 (patch)
tree0708aaf74fc7c16a8c255ca6c182d87f8f382ab6 /bitbake/lib
parent39b637ccd35803a825bc4de6ee98228273ff5744 (diff)
downloadpoky-3e1b5e0685eba0f56ad82f49e28cf8a173affad8.tar.gz
bitbake: siggen: Fix check calculation problem with file_checksums
When I enabled debugging of the checksum code, I found the value calculated from siginfo/sigdata files for do_fetch tasks never matched. This was due to an error in the way the data was being stored for these, it wasn't ordered correctly. This patch fixes things so the checksums calculated from siginfo/sigdata files is correct when file checksums are present. (Bitbake rev: 046c1be7594fae2eec3d1f242ba3e9a85f1a1880) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib')
-rw-r--r--bitbake/lib/bb/siggen.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/bitbake/lib/bb/siggen.py b/bitbake/lib/bb/siggen.py
index 114851c490..d8ba1d47a3 100644
--- a/bitbake/lib/bb/siggen.py
+++ b/bitbake/lib/bb/siggen.py
@@ -186,8 +186,9 @@ class SignatureGeneratorBasic(SignatureGenerator):
186 k = fn + "." + task 186 k = fn + "." + task
187 data = dataCache.basetaskhash[k] 187 data = dataCache.basetaskhash[k]
188 self.runtaskdeps[k] = [] 188 self.runtaskdeps[k] = []
189 self.file_checksum_values[k] = {} 189 self.file_checksum_values[k] = []
190 recipename = dataCache.pkg_fn[fn] 190 recipename = dataCache.pkg_fn[fn]
191
191 for dep in sorted(deps, key=clean_basepath): 192 for dep in sorted(deps, key=clean_basepath):
192 depname = dataCache.pkg_fn[self.pkgnameextract.search(dep).group('fn')] 193 depname = dataCache.pkg_fn[self.pkgnameextract.search(dep).group('fn')]
193 if not self.rundep_check(fn, recipename, task, dep, depname, dataCache): 194 if not self.rundep_check(fn, recipename, task, dep, depname, dataCache):
@@ -203,7 +204,7 @@ class SignatureGeneratorBasic(SignatureGenerator):
203 else: 204 else:
204 checksums = bb.fetch2.get_file_checksums(dataCache.file_checksums[fn][task], recipename) 205 checksums = bb.fetch2.get_file_checksums(dataCache.file_checksums[fn][task], recipename)
205 for (f,cs) in checksums: 206 for (f,cs) in checksums:
206 self.file_checksum_values[k][f] = cs 207 self.file_checksum_values[k].append((f,cs))
207 if cs: 208 if cs:
208 data = data + cs 209 data = data + cs
209 210
@@ -262,7 +263,7 @@ class SignatureGeneratorBasic(SignatureGenerator):
262 263
263 if runtime and k in self.taskhash: 264 if runtime and k in self.taskhash:
264 data['runtaskdeps'] = self.runtaskdeps[k] 265 data['runtaskdeps'] = self.runtaskdeps[k]
265 data['file_checksum_values'] = [(os.path.basename(f), cs) for f,cs in self.file_checksum_values[k].items()] 266 data['file_checksum_values'] = [(os.path.basename(f), cs) for f,cs in self.file_checksum_values[k]]
266 data['runtaskhashes'] = {} 267 data['runtaskhashes'] = {}
267 for dep in data['runtaskdeps']: 268 for dep in data['runtaskdeps']:
268 data['runtaskhashes'][dep] = self.taskhash[dep] 269 data['runtaskhashes'][dep] = self.taskhash[dep]