summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2016-01-07 00:15:48 +1300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-01-11 15:41:06 +0000
commit0bba4b5afd2ce2c3a79445eee886979a77f1a4d8 (patch)
treefc0af60c3e24a60c92f7e7b789d6d3857c545dee /scripts
parent0164dc66467739b357ab22bf9b8c0845f3eff4a4 (diff)
downloadopenembedded-core-0bba4b5afd2ce2c3a79445eee886979a77f1a4d8.tar.gz
openembedded-core-0bba4b5afd2ce2c3a79445eee886979a77f1a4d8.tar.bz2
openembedded-core-0bba4b5afd2ce2c3a79445eee886979a77f1a4d8.zip
devtool: sdk-update: add option to skip preparation step
For debugging purposes it's useful to be able to skip the preparation step so you can inspect what the state of the build system is first. 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/sdk.py18
1 files changed, 10 insertions, 8 deletions
diff --git a/scripts/lib/devtool/sdk.py b/scripts/lib/devtool/sdk.py
index 2d9d911e4c..7faefabad8 100644
--- a/scripts/lib/devtool/sdk.py
+++ b/scripts/lib/devtool/sdk.py
@@ -173,14 +173,15 @@ def sdk_update(args, config, basepath, workspace):
with open(os.path.join(basepath, 'conf/local.conf'), 'a') as f:
f.write('SSTATE_MIRRORS_append = " file://.* %s/sstate-cache/PATH \\n "\n' % updateserver)
- # Run bitbake command for the whole SDK
- sdk_targets = config.get('SDK', 'sdk_targets')
- logger.info("Executing 'bitbake %s' ... (This may take some time.)" % sdk_targets)
- try:
- exec_build_env_command(config.init_path, basepath, 'bitbake %s' % sdk_targets)
- except:
- logger.error('bitbake %s failed' % sdk_targets)
- return -1
+ if not args.skip_prepare:
+ # Run bitbake command for the whole SDK
+ sdk_targets = config.get('SDK', 'sdk_targets')
+ logger.info("Preparing build system... (This may take some time.)")
+ try:
+ exec_build_env_command(config.init_path, basepath, 'bitbake %s' % sdk_targets)
+ except:
+ logger.error('bitbake %s failed' % sdk_targets)
+ return -1
return 0
def register_commands(subparsers, context):
@@ -188,4 +189,5 @@ def register_commands(subparsers, context):
if context.fixed_setup:
parser_sdk = subparsers.add_parser('sdk-update', help='Update SDK components from a nominated location')
parser_sdk.add_argument('updateserver', help='The update server to fetch latest SDK components from', nargs='?')
+ parser_sdk.add_argument('--skip-prepare', action="store_true", help='Skip re-preparing the build system after updating (for debugging only)')
parser_sdk.set_defaults(func=sdk_update)