]> code.ossystems Code Review - openembedded-core.git/commitdiff
classes/populate_sdk_ext: detect and warn if running in OE environment
authorPaul Eggleton <paul.eggleton@linux.intel.com>
Mon, 19 Oct 2015 16:33:11 +0000 (17:33 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 20 Oct 2015 09:11:44 +0000 (10:11 +0100)
If you run the extensible SDK environment setup script in a shell
session where oe-init-build-env has been run already, and attempt to use
the two together, strange things happen - you may not even be running
devtool from the extensible SDK, but the OE tree. This isn't a supported
use case anyway, so show a warning recommending starting a new shell
session.

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/populate_sdk_ext.bbclass

index 060a44ae88b4dd3b629d76b1a7f1a50e41242e44..249ec363db755e2df52f0fbb1ca14dd9a4f13177 100644 (file)
@@ -238,6 +238,9 @@ sdk_ext_postinst() {
 
        echo "printf 'SDK environment now set up; additionally you may now run devtool to perform development tasks.\nRun devtool --help for further details.\n'" >> $env_setup_script
 
+       # Warn if trying to use external bitbake and the ext SDK together
+       echo "(which bitbake > /dev/null 2>&1 && echo 'WARNING: attempting to use the extensible SDK in an environment set up to run bitbake - this may lead to unexpected results. Please source this script in a new shell session instead.') || true" >> $env_setup_script
+
        # For now this is where uninative.bbclass expects the tarball
        mv *-nativesdk-libc.tar.* $target_sdk_dir/`dirname ${oe_init_build_env_path}`