]> code.ossystems Code Review - openembedded-core.git/commit
image_types.bbclass: Don't try to create ubi symlink twice
authorMike Looijmans <mike.looijmans@topic.nl>
Tue, 15 Sep 2015 09:50:39 +0000 (11:50 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 22 Sep 2015 17:05:53 +0000 (18:05 +0100)
commitfce257892488b9ef537526ccf412e9deda37c439
tree4cd59e5e1a00630b71f7c47d827d209cb9b833ae
parentf5752cefe6ee374bffadcecb2ec50bfd38376b7d
image_types.bbclass: Don't try to create ubi symlink twice

Fixes b6e64de541b37 "Restore compatibility with previous UBI filesystems"

The multivolume UBI code creates symlinks for each volume. If the volume name
is empty, it will create a symlink that the rootfs code will attempt to
create again later, resulting in a crash like this (unless IMAGE_LINK_NAME
is blank):
  ERROR: Error executing a python function in .../recipes-core/images/my-image.bb:
  File: '.../oe-core/meta/lib/oe/image.py', lineno: 203, function: _create_symlinks
   *** 0203:                    os.symlink(src, dst)
  Exception: OSError: [Errno 17] File exists

To prevent this from happening, only create symlinks to volumes that have
a name, and let the rootfs script create the default symlink later.

Signed-off-by: Mike Looijmans <mike.looijmans@topic.nl>
Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/classes/image_types.bbclass