From 88db9e41c1fe9678b3a9002457de28e3007b328a Mon Sep 17 00:00:00 2001 From: Jaewon Lee Date: Tue, 17 Sep 2019 17:37:33 -0700 Subject: populate_sdk_ext: Introduce mechanism to keep nativesdk* sstate in esdk When doing a devtool build-sdk from within an esdk all nativesdk components would be rebuilt. This patch introduces SDK_INCLUDE_NATIVESDK flag to toggle the inclusion of nativesdk packages when creating the esdk sstate Currently locked-sigs.inc is generated during do_sdk_depends which doesn't pull in nativesdk packages. Generating another locked-sigs.inc in do_populate_sdk_ext and pruning it to only nativesdk* packages by using a modified version of the already existing function prune_locked_sigs and merging it with the current locked-sigs.inc Also adding SDK_INCLUDE_NATIVESDK tasklistfn to the logic surrounding setting tasklist file to not prune esdk sstate during creation [YOCTO #13261] (From OE-Core rev: d046afd12e1c209b29dca6ba402b9aa14680c5ce) Signed-off-by: Jaewon Lee Signed-off-by: Richard Purdie --- meta/lib/oe/copy_buildsystem.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'meta/lib') diff --git a/meta/lib/oe/copy_buildsystem.py b/meta/lib/oe/copy_buildsystem.py index cb663b21c6..31a84f5b06 100644 --- a/meta/lib/oe/copy_buildsystem.py +++ b/meta/lib/oe/copy_buildsystem.py @@ -177,7 +177,7 @@ def generate_locked_sigs(sigfile, d): tasks = ['%s:%s' % (v[2], v[1]) for v in depd.values()] bb.parse.siggen.dump_lockedsigs(sigfile, tasks) -def prune_lockedsigs(excluded_tasks, excluded_targets, lockedsigs, pruned_output): +def prune_lockedsigs(excluded_tasks, excluded_targets, lockedsigs, onlynative, pruned_output): with open(lockedsigs, 'r') as infile: bb.utils.mkdirhier(os.path.dirname(pruned_output)) with open(pruned_output, 'w') as f: @@ -187,7 +187,11 @@ def prune_lockedsigs(excluded_tasks, excluded_targets, lockedsigs, pruned_output if line.endswith('\\\n'): splitval = line.strip().split(':') if not splitval[1] in excluded_tasks and not splitval[0] in excluded_targets: - f.write(line) + if onlynative: + if 'nativesdk' in splitval[0]: + f.write(line) + else: + f.write(line) else: f.write(line) invalue = False -- cgit v1.2.3-54-g00ecf