[oe-commits] [openembedded-core] 10/19: scripts/wic: explicitly set BUILDDIR within eSDK

git at git.openembedded.org git at git.openembedded.org
Thu Jan 11 23:24:10 UTC 2018


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master-next
in repository openembedded-core.

commit 564909e1688e209dded47cb7ae829aeb2b76b370
Author: Chang Rebecca Swee Fun <rebecca.swee.fun.chang at intel.com>
AuthorDate: Thu Jan 11 22:55:22 2018 +0800

    scripts/wic: explicitly set BUILDDIR within eSDK
    
    When we run wic within eSDK:
    $ wic create mkefidisk -e core-image-minimal
    
    ERROR: BUILDDIR not found, exiting. (Did you forget to source oe-init-build-env?)
    
    In order to figure out variable values, one must have sourced
    the OE build environment setup script. However, when we are in
    within the eSDK environment which isn't initialised like the
    normal OE build environment, we can't use wic utility with eSDK.
    
    Reference:
    https://www.yoctoproject.org/docs/latest/mega-manual/mega-manual.html#wic-requirements
    
    While wic ought to be fixed to be able to run without bitbake
    & native tools [YOCTO #11281], but this is a workaround to set
    BUILDDIR in the environment so that bitbake environment is setup
    for wic to build its required native tools.
    
    Signed-off-by: Chang Rebecca Swee Fun <rebecca.swee.fun.chang at intel.com>
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 scripts/wic | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/scripts/wic b/scripts/wic
index d9bea22..7392bc4 100755
--- a/scripts/wic
+++ b/scripts/wic
@@ -51,6 +51,8 @@ sdkroot = scripts_path
 if os.environ.get('SDKTARGETSYSROOT'):
     while sdkroot != '' and sdkroot != os.sep:
         if os.path.exists(os.path.join(sdkroot, '.devtoolbase')):
+            # Set BUILDDIR for wic to work within eSDK
+            os.environ['BUILDDIR'] = sdkroot
             # .devtoolbase only exists within eSDK
             # If found, initialize bitbake path for eSDK environment and append to PATH
             sdkroot = os.path.join(os.path.dirname(scripts_path), 'bitbake', 'bin')

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list