From 7b8ee9285a197784d51e339f1603240f49435846 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Fri, 5 Jan 2018 15:14:35 +0000 Subject: bitbake.conf: Set AUTOREV to have a vardepvalue If you have a recipe which does not include SRCPV in PV but does set SRCREV = "${AUTOREV}" and you run do_fetch, then change the repo to a new commit then run do_unpack, do_unpack will fail since the new commit doesn't exist in the repo that was fetched. The problem is the revision chosen is not represented in the do_fetch task hash. It if were, the fetch would rerun first and the commit would be present. It works when PV includes SRCPV since that does contain the chosen commit from the AUTOREV. The solution is to include the SRCPV value into the representation of AUTOREV used for checksum calculation purposes. Add a selftest for this issue. Signed-off-by: Richard Purdie --- meta/conf/bitbake.conf | 1 + 1 file changed, 1 insertion(+) (limited to 'meta/conf/bitbake.conf') diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf index 15feb573db..93afb13166 100644 --- a/meta/conf/bitbake.conf +++ b/meta/conf/bitbake.conf @@ -663,6 +663,7 @@ FETCHCMD_hg = "/usr/bin/env hg" SRCDATE = "${DATE}" SRCREV ??= "INVALID" AUTOREV = "${@bb.fetch2.get_autorev(d)}" +AUTOREV[vardepvalue] = "${SRCPV}" # Set Dynamically in base.bbclass # SRCPV = "${@bb.fetch2.get_srcrev(d)}" SRCPV[vardepvalue] = "${SRCPV}" -- cgit 1.2.3-korg