]> code.ossystems Code Review - openembedded-core.git/commitdiff
bitbake-layers/create: add LAYERSERIES_COMPAT
authorAnuj Mittal <anuj.mittal@intel.com>
Mon, 11 Jun 2018 08:29:01 +0000 (16:29 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 18 Jun 2018 09:59:33 +0000 (10:59 +0100)
Derive the value for template layer.conf from core layer and add
dependendency on it too.

Fixes [YOCTO #12767]

Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/lib/bblayers/create.py
meta/lib/bblayers/templates/layer.conf

index c1923166fdbe7eed0f64d04d74727cdab7b5b602..e06949c92b75422fb1bf6ba08a8bd2e050173edb 100644 (file)
@@ -43,8 +43,11 @@ class CreatePlugin(LayerPlugin):
         license_dst = os.path.join(layerdir, copying)
         shutil.copy(license_src, license_dst)
 
+        # Get the compat value for core layer.
+        compat = self.tinfoil.config_data.getVar('LAYERSERIES_COMPAT_core') or ""
+
         # Create the layer.conf from templates/layer.conf
-        layerconf_template = read_template('layer.conf') % (args.layerdir, args.layerdir, args.layerdir, args.priority)
+        layerconf_template = read_template('layer.conf') % (args.layerdir, args.layerdir, args.layerdir, args.priority, args.layerdir, args.layerdir, compat)
         layerconf = os.path.join(conf, 'layer.conf')
         with open(layerconf, 'w') as fd:
             fd.write(layerconf_template)
index 3c0300226c599122d582f8e1a939a2c6cddb78cc..49f95cafc820026038571dd5d71ce1edbf30974f 100644 (file)
@@ -8,3 +8,6 @@ BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
 BBFILE_COLLECTIONS += "%s"
 BBFILE_PATTERN_%s = "^${LAYERDIR}/"
 BBFILE_PRIORITY_%s = "%s"
+
+LAYERDEPENDS_%s = "core"
+LAYERSERIES_COMPAT_%s = "%s"