summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick Ohly <patrick.ohly@intel.com>2017-05-04 16:42:41 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-05-18 14:01:46 +0100
commitc2221c4ca14e72196589993ff5a06175dc062c6f (patch)
tree36517bfa50e53578f157bfe4390e75144ed3d105
parentb71c46f3006ced0c265a84ce5e94eb23d2c57456 (diff)
downloadpoky-c2221c4ca14e72196589993ff5a06175dc062c6f.tar.gz
archiver.bbclass: enhance do_ar_recipe task signature
Previously, do_ar_recipe ran again unnecessarily when adding or removing classes like buildhistory.bbclass, because that changes the BBINCLUDED variable which do_ar_recipe uses to find .bbappend files. This is both extra work and also sometimes triggered "basehash changed" errors (seen under oe-selftest, which adds machine.inc and bblayers.inc) because BBINCLUDED is special and does not cause the basehash to be recalculated. The file *content* already was not considered in the task signature, instead relying indirectly on PF (which includes the revision assigned by a PR server) to ensure that a new versioned source archive gets created each time there is a rebuild. Therefore it makes sense to use the same mechanism and also ignore the file *list*, i.e. exclude BBINCLUDED from the task signature. (From OE-Core rev: 9666f0e0b02efc14226c77497fd38f79fc372f98) Signed-off-by: Patrick Ohly <patrick.ohly@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes/archiver.bbclass13
1 files changed, 13 insertions, 0 deletions
diff --git a/meta/classes/archiver.bbclass b/meta/classes/archiver.bbclass
index 2c04557f79..82751c1e73 100644
--- a/meta/classes/archiver.bbclass
+++ b/meta/classes/archiver.bbclass
@@ -330,6 +330,19 @@ python do_unpack_and_patch() {
330 bb.utils.remove(src_orig, recurse=True) 330 bb.utils.remove(src_orig, recurse=True)
331} 331}
332 332
333# BBINCLUDED is special (excluded from basehash signature
334# calculation). Using it in a task signature can cause "basehash
335# changed" errors.
336#
337# Depending on BBINCLUDED also causes do_ar_recipe to run again
338# for unrelated changes, like adding or removing buildhistory.bbclass.
339#
340# For these reasons we ignore the dependency completely. The versioning
341# of the output file ensures that we create it each time the recipe
342# gets rebuilt, at least as long as a PR server is used. We also rely
343# on that mechanism to catch changes in the file content, because the
344# file content is not part of of the task signature either.
345do_ar_recipe[vardepsexclude] += "BBINCLUDED"
333python do_ar_recipe () { 346python do_ar_recipe () {
334 """ 347 """
335 archive the recipe, including .bb and .inc. 348 archive the recipe, including .bb and .inc.