From 9e096eba81a5ba6eaa9edb5927c052d5b099a7ea Mon Sep 17 00:00:00 2001 From: Max Krummenacher Date: Thu, 12 Nov 2020 11:51:14 +0100 Subject: uprev-srcrev: change fetch policy to fetch from remote repo Force BB_SRCREV_POLICY to 'clear'. Thus the fetcher queries the remote git repo for the latest HEAD and does not rely on the copy in the local download directory. With this, we can change CI to run uprev-srcrev before building the images if we want to build latest HEAD of our components rather than using AUTOREV through use-head-next. This prevents that a push to the repos during a build might cause build errors. Related-to: AUT-528 Signed-off-by: Max Krummenacher --- scripts/uprev-srcrev | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/uprev-srcrev b/scripts/uprev-srcrev index dffb993..4e9511e 100755 --- a/scripts/uprev-srcrev +++ b/scripts/uprev-srcrev @@ -49,7 +49,9 @@ def uprev_recipe(args, env, recipe): def uprev(args): env = os.environ.copy() - env['BB_SRCREV_POLICY'] = "cache" + # make sure that we query the remote repo as we execute the script, not + # the clone we have in the local download. + env['BB_SRCREV_POLICY'] = "clear" for recipe in recipes: logger.info('Processing recipe {}'.format(recipe)) uprev_recipe(args, env, recipe) -- cgit v1.2.3