create_tarball: Force file permissions in the tarball.

It addresses independence from UMASK to ensure a reproducible build.

Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
(cherry picked from commit 807378eeb2)
r14.0.x
Slávek Banko 4 years ago
parent 3bff5cbf91
commit 23145430b1
No known key found for this signature in database
GPG Key ID: 608F5293A04BE668

@ -154,6 +154,7 @@ if [ ! -e $TARBALL_DIR/$package.tar$TAR_SUFFIX ]; then
trap "rm $TARBALL_DIR/tar-$$; rm .tdescminfo; exit 1" INT
find ./ -print0 | LC_ALL=C sort -z | \
tar c --no-recursion --null -T - \
--mode=u+rw,go=rX,a-s \
--mtime "@$(git log -1 --pretty=format:"%ct")" \
--owner=root --group=users --exclude .git --exclude .gitmodules \
--pax-option=exthdr.name=%d/PaxHeaders/%f,delete=atime,delete=ctime \

Loading…
Cancel
Save