[oe-commits] [openembedded-core] 70/83: classes/populate_sdk_ext: prevent invalid TEMPLATECONF entering eSDK

git at git.openembedded.org git at git.openembedded.org
Sun Nov 6 23:37:22 UTC 2016


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

commit 5ee32191a18013061dfa72e64713a94c5d321496
Author: Paul Eggleton <paul.eggleton at linux.intel.com>
AuthorDate: Wed Nov 2 15:31:05 2016 +1300

    classes/populate_sdk_ext: prevent invalid TEMPLATECONF entering eSDK
    
    If you are using a repository which contains a .templateconf file that
    sets TEMPLATECONF to point into a layer it contains, but you aren't
    using that layer in your bblayers.conf, the eSDK would produce an error
    during the preparation step of the installation. An example would be
    using the poky repository but setting DISTRO to your own custom distro
    and removing meta-poky from your bblayers.conf. The eSDK doesn't
    support creating new build directories, so we don't care about the
    templates and can thus force a known good value to prevent this from
    happening.
    
    Fixes [YOCTO #10568].
    
    Signed-off-by: Paul Eggleton <paul.eggleton at linux.intel.com>
    Signed-off-by: Ross Burton <ross.burton at intel.com>
---
 meta/classes/populate_sdk_ext.bbclass | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/meta/classes/populate_sdk_ext.bbclass b/meta/classes/populate_sdk_ext.bbclass
index 0f0525d..944fe5c 100644
--- a/meta/classes/populate_sdk_ext.bbclass
+++ b/meta/classes/populate_sdk_ext.bbclass
@@ -88,7 +88,7 @@ SDK_TITLE_task-populate-sdk-ext = "${@d.getVar('DISTRO_NAME', True) or d.getVar(
 def clean_esdk_builddir(d, sdkbasepath):
     """Clean up traces of the fake build for create_filtered_tasklist()"""
     import shutil
-    cleanpaths = 'cache conf/sanity_info conf/templateconf.cfg tmp'.split()
+    cleanpaths = 'cache conf/sanity_info tmp'.split()
     for pth in cleanpaths:
         fullpth = os.path.join(sdkbasepath, pth)
         if os.path.isdir(fullpth):
@@ -344,6 +344,10 @@ python copy_buildsystem () {
                     if line.strip() and not line.startswith('#'):
                         f.write(line)
 
+    # Write a templateconf.cfg
+    with open(baseoutpath + '/conf/templateconf.cfg', 'w') as f:
+        f.write('meta/conf\n')
+
     # Ensure any variables set from the external environment (by way of
     # BB_ENV_EXTRAWHITE) are set in the SDK's configuration
     extralines = []

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


More information about the Openembedded-commits mailing list