summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2016-05-09 14:07:17 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-05-11 10:34:30 +0100
commit442acd2ea910609b4ad1d22a6522d3d9128c7100 (patch)
tree3b5fff7b8829e443865203d168de3def6a55bde7 /bitbake/lib/bb
parent3795f4d6a69dc4ba5208f1d05b89e65bc11d8a10 (diff)
downloadpoky-442acd2ea910609b4ad1d22a6522d3d9128c7100.tar.gz
bitbake: lib/bb/utils.py: Fix explode_dep_versions2() determinism issue
When we pass data into explode_dep_versions2(), we need to result to be able to be processed in a deterministic way so that we end up with consistent hash values. This means we need an ordered structure rather than an unordered one. To do this, return an OrderedDict() rather than a dict(). (Bitbake rev: 0737e003ca549d08a7dfe13452ae982f2e11fecd) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r--bitbake/lib/bb/utils.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/bitbake/lib/bb/utils.py b/bitbake/lib/bb/utils.py
index 2abf518ece..0c553dd765 100644
--- a/bitbake/lib/bb/utils.py
+++ b/bitbake/lib/bb/utils.py
@@ -36,6 +36,7 @@ import traceback
36import errno 36import errno
37import signal 37import signal
38import ast 38import ast
39import collections
39from commands import getstatusoutput 40from commands import getstatusoutput
40from contextlib import contextmanager 41from contextlib import contextmanager
41from ctypes import cdll 42from ctypes import cdll
@@ -192,7 +193,7 @@ def explode_dep_versions2(s):
192 "DEPEND1 (optional version) DEPEND2 (optional version) ..." 193 "DEPEND1 (optional version) DEPEND2 (optional version) ..."
193 and return a dictionary of dependencies and versions. 194 and return a dictionary of dependencies and versions.
194 """ 195 """
195 r = {} 196 r = collections.OrderedDict()
196 l = s.replace(",", "").split() 197 l = s.replace(",", "").split()
197 lastdep = None 198 lastdep = None
198 lastcmp = "" 199 lastcmp = ""