From 49858bdc02b8bada1943acd9c77318f71917a6c2 Mon Sep 17 00:00:00 2001 From: Paul Eggleton Date: Mon, 23 Nov 2015 10:07:57 +1300 Subject: devtool: upgrade: fetch remote repository before checking out new revision If we're upgrading a recipe that fetches from git, and we've simply fetched a tarball of the repo instead of directly from the upstream repo (this can happen if you have PREMIRRORS set up as in poky with a core recipe, e.g. kernelshark) then we won't have any new revisions, and the checkout will fail with "fatal: reference is not a tree: ". To avoid this, do a "git fetch" before checking out the new revision. (From OE-Core master rev: c4daebf3fe797a8063dcbc2ab229be2fbedc8134) (From OE-Core rev: 2c8afd6aae775ab10dd30eb890fc410739048d79) Signed-off-by: Paul Eggleton Signed-off-by: Ross Burton Signed-off-by: Richard Purdie --- scripts/lib/devtool/upgrade.py | 1 + 1 file changed, 1 insertion(+) (limited to 'scripts') diff --git a/scripts/lib/devtool/upgrade.py b/scripts/lib/devtool/upgrade.py index f033fc8010..6bac44bb5c 100644 --- a/scripts/lib/devtool/upgrade.py +++ b/scripts/lib/devtool/upgrade.py @@ -199,6 +199,7 @@ def _extract_new_source(newpv, srctree, no_patch, srcrev, branch, keep_temp, tin if srcrev: rev = srcrev if uri.startswith('git://'): + __run('git fetch') __run('git checkout %s' % rev) __run('git tag -f devtool-base-new') md5 = None -- cgit v1.2.3-54-g00ecf