If IMAGE_LINK_NAME is empty don't try to create the symlink. [YOCTO #14042]
Signed-off-by: Diego Sueiro <[email protected]> --- meta/classes/license_image.bbclass | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/meta/classes/license_image.bbclass b/meta/classes/license_image.bbclass index 682d462..702e9f9 100644 --- a/meta/classes/license_image.bbclass +++ b/meta/classes/license_image.bbclass @@ -200,14 +200,16 @@ def license_deployed_manifest(d): image_license_manifest = os.path.join(lic_manifest_dir, 'image_license.manifest') write_license_files(d, image_license_manifest, man_dic, rootfs=False) - lic_manifest_symlink_dir = os.path.join(d.getVar('LICENSE_DIRECTORY'), - d.getVar('IMAGE_LINK_NAME')) - # remove old symlink - if os.path.islink(lic_manifest_symlink_dir): - os.unlink(lic_manifest_symlink_dir) - - # create the image dir symlink - os.symlink(lic_manifest_dir, lic_manifest_symlink_dir) + link_name = d.getVar('IMAGE_LINK_NAME') + if link_name: + lic_manifest_symlink_dir = os.path.join(d.getVar('LICENSE_DIRECTORY'), + link_name) + # remove old symlink + if os.path.islink(lic_manifest_symlink_dir): + os.unlink(lic_manifest_symlink_dir) + + # create the image dir symlink + os.symlink(lic_manifest_dir, lic_manifest_symlink_dir) def get_deployed_dependencies(d): """ -- 2.7.4
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#142435): https://lists.openembedded.org/g/openembedded-core/message/142435 Mute This Topic: https://lists.openembedded.org/mt/76777225/21656 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
