mirror of
https://git.yoctoproject.org/poky
synced 2026-04-21 03:32:12 +02:00
buildhistory: force writing SRCREV values
Enabling SSTATE_MIRRORS sometimes causes SRCREV values not
to be written/updated in the build history. This happens more
often if SRCREV is set to ${AUTOREV}
Explicitly writing SRCREVs when recipe history is being written
should fix this.
[YOCTO #10948]
(From OE-Core rev: df74b97599a789db742fc7588009783f5f37ebff)
Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
437f9cdbaf
commit
62f4629066
@@ -336,6 +336,7 @@ def write_recipehistory(rcpinfo, d):
|
||||
f.write(u"PACKAGES = %s\n" % rcpinfo.packages)
|
||||
f.write(u"LAYER = %s\n" % rcpinfo.layer)
|
||||
|
||||
write_latest_srcrev(d, pkghistdir)
|
||||
|
||||
def write_pkghistory(pkginfo, d):
|
||||
bb.debug(2, "Writing package history for package %s" % pkginfo.name)
|
||||
@@ -856,7 +857,10 @@ def _get_srcrev_values(d):
|
||||
do_fetch[postfuncs] += "write_srcrev"
|
||||
do_fetch[vardepsexclude] += "write_srcrev"
|
||||
python write_srcrev() {
|
||||
pkghistdir = d.getVar('BUILDHISTORY_DIR_PACKAGE')
|
||||
write_latest_srcrev(d, d.getVar('BUILDHISTORY_DIR_PACKAGE'))
|
||||
}
|
||||
|
||||
def write_latest_srcrev(d, pkghistdir):
|
||||
srcrevfile = os.path.join(pkghistdir, 'latest_srcrev')
|
||||
|
||||
srcrevs, tag_srcrevs = _get_srcrev_values(d)
|
||||
@@ -894,4 +898,3 @@ python write_srcrev() {
|
||||
else:
|
||||
if os.path.exists(srcrevfile):
|
||||
os.remove(srcrevfile)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user