From 92eb42c347af919cd9f8739515fdf806c12b5ba8 Mon Sep 17 00:00:00 2001 From: Paul Eggleton Date: Thu, 14 Jul 2016 09:04:24 +1200 Subject: devtool: upgrade: record original recipe files This provides us with the information we need to remove the original version recipe and associated files when running "devtool finish" after "devtool upgrade". Signed-off-by: Paul Eggleton Signed-off-by: Ross Burton --- meta/lib/oe/recipeutils.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'meta/lib') diff --git a/meta/lib/oe/recipeutils.py b/meta/lib/oe/recipeutils.py index cb4ed53d0f..b8d481aeb8 100644 --- a/meta/lib/oe/recipeutils.py +++ b/meta/lib/oe/recipeutils.py @@ -365,6 +365,7 @@ def copy_recipe_files(d, tgt_dir, whole_dir=False, download=True): # Copy local files to target directory and gather any remote files bb_dir = os.path.dirname(d.getVar('FILE', True)) + os.sep remotes = [] + copied = [] includes = [path for path in d.getVar('BBINCLUDED', True).split() if path.startswith(bb_dir) and os.path.exists(path)] for path in fetch.localpaths() + includes: @@ -376,13 +377,14 @@ def copy_recipe_files(d, tgt_dir, whole_dir=False, download=True): if not os.path.exists(subdir): os.makedirs(subdir) shutil.copy2(path, os.path.join(tgt_dir, relpath)) + copied.append(relpath) else: remotes.append(path) # Simply copy whole meta dir, if requested if whole_dir: shutil.copytree(bb_dir, tgt_dir) - return remotes + return copied, remotes def get_recipe_local_files(d, patches=False): -- cgit 1.2.3-korg