1
0
mirror of https://git.yoctoproject.org/poky synced 2026-06-01 13:09:50 +00:00

bitbake: lib/bb/utils.py: Preserve ownership of symlink

Yocto Bug: https://bugzilla.yoctoproject.org/show_bug.cgi?id=13806

Uncomment lchown() to preserve ownership of symlink.

(Bitbake rev: 6836184ef5220488a1127413c7d2e523fc37e2e9)

Signed-off-by: Daisuke Yamane <daisuke.yamane@cybertrust.co.jp>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Daisuke Yamane
2020-02-22 06:17:14 +00:00
committed by Richard Purdie
parent 5e1f52edb7
commit 7f5914015b
+1 -1
View File
@@ -851,7 +851,7 @@ def copyfile(src, dest, newmtime = None, sstat = None):
if destexists and not stat.S_ISDIR(dstat[stat.ST_MODE]):
os.unlink(dest)
os.symlink(target, dest)
#os.lchown(dest,sstat[stat.ST_UID],sstat[stat.ST_GID])
os.lchown(dest,sstat[stat.ST_UID],sstat[stat.ST_GID])
return os.lstat(dest)
except Exception as e:
logger.warning("copyfile: failed to create symlink %s to %s (%s)" % (dest, target, e))