[oe-commits] [openembedded-core] 04/20: archiver.bbclass: enhance do_ar_recipe task signature

git at git.openembedded.org git at git.openembedded.org
Sun Jan 7 17:12:05 UTC 2018


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch pyro
in repository openembedded-core.

commit 62fbbf99de7b427d95f51d63039ab5a803209904
Author: Patrick Ohly <patrick.ohly at intel.com>
AuthorDate: Thu May 4 16:42:41 2017 +0200

    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)
    
    (From OE-Core rev: f560bfe15d283c59094a0f7987fad10baad053b4)
    
    Signed-off-by: Patrick Ohly <patrick.ohly at intel.com>
    Signed-off-by: Ross Burton <ross.burton at intel.com>
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 meta/classes/archiver.bbclass | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/meta/classes/archiver.bbclass b/meta/classes/archiver.bbclass
index 9cc9fb5..fb0c77d 100644
--- a/meta/classes/archiver.bbclass
+++ b/meta/classes/archiver.bbclass
@@ -330,6 +330,19 @@ python do_unpack_and_patch() {
         bb.utils.remove(src_orig, recurse=True)
 }
 
+# BBINCLUDED is special (excluded from basehash signature
+# calculation). Using it in a task signature can cause "basehash
+# changed" errors.
+#
+# Depending on BBINCLUDED also causes do_ar_recipe to run again
+# for unrelated changes, like adding or removing buildhistory.bbclass.
+#
+# For these reasons we ignore the dependency completely. The versioning
+# of the output file ensures that we create it each time the recipe
+# gets rebuilt, at least as long as a PR server is used. We also rely
+# on that mechanism to catch changes in the file content, because the
+# file content is not part of of the task signature either.
+do_ar_recipe[vardepsexclude] += "BBINCLUDED"
 python do_ar_recipe () {
     """
     archive the recipe, including .bb and .inc.

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list