mirror of
https://git.yoctoproject.org/poky
synced 2026-05-08 05:09:24 +00:00
bitbake: fetch2/git: canonicalize ids in generated tarballs
Change the owner information in the mirror tarballs generated using BB_GENERATE_MIRROR_TARBALLS="1". This is an extension of commit 0178ab83, which used the original pokybuild:user information, but failed to clean up the numerical user and group ids. Now set the more canonical values of oe:oe and 0:0. (Bitbake rev: 37437115d3fb1a9f5d8ed7356a0fc01a408e4f8c) Signed-off-by: Olaf Mandel <o.mandel@menlosystems.com> CC: Marek Vasut <marex@denx.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
73d0fcf5d5
commit
d1f254d56f
@@ -464,7 +464,7 @@ class Git(FetchMethod):
|
||||
with create_atomic(ud.fullmirror) as tfile:
|
||||
mtime = runfetchcmd("git log --all -1 --format=%cD", d,
|
||||
quiet=True, workdir=ud.clonedir)
|
||||
runfetchcmd("tar -czf %s --owner pokybuild --group users --mtime \"%s\" ."
|
||||
runfetchcmd("tar -czf %s --owner oe:0 --group oe:0 --mtime \"%s\" ."
|
||||
% (tfile, mtime), d, workdir=ud.clonedir)
|
||||
runfetchcmd("touch %s.done" % ud.fullmirror, d)
|
||||
|
||||
|
||||
@@ -653,8 +653,10 @@ class CleanTarballTest(FetcherTest):
|
||||
archive = tarfile.open(os.path.join(self.dldir, self.recipe_tarball))
|
||||
self.assertNotEqual(len(archive.members), 0)
|
||||
for member in archive.members:
|
||||
self.assertEqual(member.uname, 'pokybuild')
|
||||
self.assertEqual(member.gname, 'users')
|
||||
self.assertEqual(member.uname, 'oe')
|
||||
self.assertEqual(member.uid, 0)
|
||||
self.assertEqual(member.gname, 'oe')
|
||||
self.assertEqual(member.gid, 0)
|
||||
self.assertEqual(member.mtime, mtime)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user