summaryrefslogtreecommitdiff
path: root/scripts/lib
diff options
context:
space:
mode:
authorAníbal Limón <anibal.limon@linux.intel.com>2017-03-27 11:05:30 -0600
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-03-28 16:18:31 +0100
commit39103285029a0bb7b64dc5a305c484988b4c651a (patch)
treee0579feb5bf5483989e9e9319204d47608dfc7bb /scripts/lib
parent466e6e45ca04a07ebe1b1f52de747f077b362d54 (diff)
downloadopenembedded-core-39103285029a0bb7b64dc5a305c484988b4c651a.tar.gz
openembedded-core-39103285029a0bb7b64dc5a305c484988b4c651a.tar.bz2
openembedded-core-39103285029a0bb7b64dc5a305c484988b4c651a.zip
scripts/yocto-compat-layer.py: Add dependency validation in add_layer
Some layers don't have dependencies so add a validation to avoid exception when trying to None.split(). Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/lib')
-rw-r--r--scripts/lib/compatlayer/__init__.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/lib/compatlayer/__init__.py b/scripts/lib/compatlayer/__init__.py
index 435679edbf..58f94b778b 100644
--- a/scripts/lib/compatlayer/__init__.py
+++ b/scripts/lib/compatlayer/__init__.py
@@ -143,7 +143,11 @@ def add_layer(bblayersconf, layer, layers, logger):
logger.info('Adding layer %s' % layer['name'])
for collection in layer['collections']:
- for depend in layer['collections'][collection]['depends'].split():
+ depends = layer['collections'][collection]['depends']
+ if not depends:
+ continue
+
+ for depend in depends.split():
# core (oe-core) is suppose to be provided
if depend == 'core':
continue