summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2017-08-31 11:54:05 +1200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-08-31 23:30:02 +0100
commit24cfac526305e623f368152147497b39cb26044c (patch)
treeacd301ba757715db3dd3047acefb40c9ce481eeb /scripts
parent52d71c17ffd2d58699bf05bc85e0dd0d49e51021 (diff)
downloadpoky-24cfac526305e623f368152147497b39cb26044c.tar.gz
devtool: update-recipe: ensure patches get deleted in srcrev mode
Patches that we identify as having been "deleted" (i.e. patches in SRC_URI that no longer appear in the git tree) need to be dropped even if we're updating in srcrev mode. This fixes the case where HEAD of the git tree is valid upstream (i.e. no extra commits), but there are patches left over in the recipe, e.g. when we do devtool upgrade and then all of the commits rebased on top of the new branch get skipped. Fixes [YOCTO #11972]. (From OE-Core rev: 350f83dc1e317aeb93539f13966caca6d894f569) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/lib/devtool/standard.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/lib/devtool/standard.py b/scripts/lib/devtool/standard.py
index fa9d347693..d79ebf1a4e 100644
--- a/scripts/lib/devtool/standard.py
+++ b/scripts/lib/devtool/standard.py
@@ -1352,9 +1352,10 @@ def _update_recipe_srcrev(srctree, rd, appendlayerdir, wildcard_version, no_remo
1352 old_srcrev = (rd.getVar('SRCREV', False) or '') 1352 old_srcrev = (rd.getVar('SRCREV', False) or '')
1353 upd_p, new_p, del_p = _export_patches(srctree, rd, old_srcrev, 1353 upd_p, new_p, del_p = _export_patches(srctree, rd, old_srcrev,
1354 patches_dir) 1354 patches_dir)
1355 logger.debug('Patches: update %s, new %s, delete %s' % (dict(upd_p), dict(new_p), dict(del_p)))
1355 1356
1356 # Remove deleted local files and "overlapping" patches 1357 # Remove deleted local files and "overlapping" patches
1357 remove_files = list(del_f.values()) + list(upd_p.values()) 1358 remove_files = list(del_f.values()) + list(upd_p.values()) + list(del_p.values())
1358 if remove_files: 1359 if remove_files:
1359 removedentries = _remove_file_entries(srcuri, remove_files)[0] 1360 removedentries = _remove_file_entries(srcuri, remove_files)[0]
1360 update_srcuri = True 1361 update_srcuri = True