summaryrefslogtreecommitdiffstats
path: root/scripts/lib/compatlayer/__init__.py
diff options
context:
space:
mode:
authorPatrick Ohly <patrick.ohly@intel.com>2017-04-12 17:44:25 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-04-13 10:54:10 +0100
commitde76d1cc94c5a59000fbca9d5e53a5917f4e3041 (patch)
tree4cf1e1c97c41c296ccd8816ec5375d87003eb769 /scripts/lib/compatlayer/__init__.py
parent40d17719441c3e6865b0f35b40c2f98386671903 (diff)
downloadpoky-de76d1cc94c5a59000fbca9d5e53a5917f4e3041.tar.gz
yocto-compat-layer: test signature differences when setting MACHINE
Selecting a machine is only allowed to affect the signature of tasks that are specific to that machine. In other words, when MACHINE=A and MACHINE=B share a recipe foo and the output of foo, then both machine configurations must build foo in exactly the same way. Otherwise it is not possible to use both machines in the same distribution. This criteria can only be tested by testing different machines in combination, i.e. one main layer, potentially several additional BSP layers and an explicit choice of machines: yocto-compat-layer --additional-layers .../meta-intel --machines intel-corei7-64 imx6slevk -- .../meta-freescale To simplify the analysis and limit the amount of output, mismatches are sorted by task order such that tasks that run first are also reported first. Following tasks for the same recipe and set of machines then get pruned, because they are likely to be different because of the underlying task (same approach as in test_signatures). The difference here is that we get information about all machines. The task order in the base configuration serves as heuristic for sorting that merged list. The test has already found issues in go-cross (depended on tune-specific libgcc) and gdb-cross (had a tune-specific path unnecessarily), so it is also useful to uncover issues that are not caused by the BSP layer itself. (From OE-Core rev: cb0d3de4540e412cfcb7804b4b1689141c80e3a1) Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/lib/compatlayer/__init__.py')
-rw-r--r--scripts/lib/compatlayer/__init__.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/lib/compatlayer/__init__.py b/scripts/lib/compatlayer/__init__.py
index 6130b8548c..0d6f4e9c3b 100644
--- a/scripts/lib/compatlayer/__init__.py
+++ b/scripts/lib/compatlayer/__init__.py
@@ -215,7 +215,7 @@ def check_command(error_msg, cmd):
215 raise RuntimeError(msg) 215 raise RuntimeError(msg)
216 return output 216 return output
217 217
218def get_signatures(builddir, failsafe=False): 218def get_signatures(builddir, failsafe=False, machine=None):
219 import re 219 import re
220 220
221 # some recipes needs to be excluded like meta-world-pkgdata 221 # some recipes needs to be excluded like meta-world-pkgdata
@@ -226,7 +226,10 @@ def get_signatures(builddir, failsafe=False):
226 sigs = {} 226 sigs = {}
227 tune2tasks = {} 227 tune2tasks = {}
228 228
229 cmd = 'bitbake ' 229 cmd = ''
230 if machine:
231 cmd += 'MACHINE=%s ' % machine
232 cmd += 'bitbake '
230 if failsafe: 233 if failsafe:
231 cmd += '-k ' 234 cmd += '-k '
232 cmd += '-S none world' 235 cmd += '-S none world'