tde_create_tarball: Add options to make tarballs reproducible

independently of UMASK and time zone.

Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
pull/64/head
Slávek Banko 4 years ago
parent 28260f0078
commit 7b6865d9e6
No known key found for this signature in database
GPG Key ID: 608F5293A04BE668

@ -2309,11 +2309,12 @@ macro( tde_create_tarball )
if( "${TAR_VERSION}" MATCHES "GNU *tar" )
set( TAR_SETOWNER "--owner=root;--group=root" )
set( TAR_REPRODUCIBLE "--pax-option=exthdr.name=%d/PaxHeaders/%f,delete=atime,delete=ctime" )
list( APPEND TAR_REPRODUCIBLE "--mode=u+rw,go=rX,a-s" )
tde_read_src_metadata()
if( TDE_PKG_DATETIME )
list( APPEND TAR_REPRODUCIBLE --mtime "${TDE_PKG_DATETIME}" )
list( APPEND TAR_REPRODUCIBLE --mtime "${TDE_PKG_DATETIME} UTC" )
elseif( TDE_SCM_MODULE_DATETIME )
list( APPEND TAR_REPRODUCIBLE --mtime "${TDE_SCM_MODULE_DATETIME}" )
list( APPEND TAR_REPRODUCIBLE --mtime "${TDE_SCM_MODULE_DATETIME} UTC" )
endif( )
elseif( "${TAR_VERSION}" MATCHES "bsd *tar" )
set( TAR_SETOWNER "--uname=root;--gname=root" )

Loading…
Cancel
Save