diff options
author | Mike Looijmans <mike.looijmans@topic.nl> | 2021-02-05 15:53:33 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2021-02-06 09:03:00 +0000 |
commit | 2fcbd0f11547d21bd18dbbc555a95a531beb5e63 (patch) | |
tree | 3f8d22a076f3eaf28a9c28831b67269400e43822 /meta | |
parent | c0ec68956cd8a7e6415431f7de373b299ee80d61 (diff) | |
download | poky-2fcbd0f11547d21bd18dbbc555a95a531beb5e63.tar.gz |
license_image.bbclass: Don't attempt to symlink to the same file
Sometimes (that is, in all my builds) the lic_manifest_dir and
lic_manifest_symlink_dir end up pointing to the same file, resulting
in an error like this:
Exception: FileExistsError: [Errno 17] File exists: '/.../tmp-glibc/deploy/licenses/my-image-tdkz15' -> '/.../tmp-glibc/deploy/licenses/my-image-tdkz15'
First check to see if this is the case before attempting to create
the link.
(From OE-Core rev: 50f83fb542065eaf7a20ac07b63ae06441ada180)
Signed-off-by: Mike Looijmans <mike.looijmans@topic.nl>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/classes/license_image.bbclass | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/meta/classes/license_image.bbclass b/meta/classes/license_image.bbclass index 8fd88cfb2d..36ddd84805 100644 --- a/meta/classes/license_image.bbclass +++ b/meta/classes/license_image.bbclass | |||
@@ -210,7 +210,8 @@ def license_deployed_manifest(d): | |||
210 | os.unlink(lic_manifest_symlink_dir) | 210 | os.unlink(lic_manifest_symlink_dir) |
211 | 211 | ||
212 | # create the image dir symlink | 212 | # create the image dir symlink |
213 | os.symlink(lic_manifest_dir, lic_manifest_symlink_dir) | 213 | if lic_manifest_dir != lic_manifest_symlink_dir: |
214 | os.symlink(lic_manifest_dir, lic_manifest_symlink_dir) | ||
214 | 215 | ||
215 | def get_deployed_dependencies(d): | 216 | def get_deployed_dependencies(d): |
216 | """ | 217 | """ |