mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: Guillermo Rodriguez <guille.rodriguez@gmail.com>
To: ptxdist@pengutronix.de
Cc: Guillermo Rodriguez <guille.rodriguez@gmail.com>
Subject: [ptxdist] [PATCH] Make sure tar archives created from svn URLs are reproducible.
Date: Wed, 29 Mar 2017 12:35:27 +0200	[thread overview]
Message-ID: <1490783727-31494-1-git-send-email-guille.rodriguez@gmail.com> (raw)

By default, tar.gz archives store a mod time in the gzip header.
This means that archives created from the same files will still
have different md5 sums. Fix this by passing gzip option -n to tar.
---
 scripts/lib/ptxd_make_get.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/lib/ptxd_make_get.sh b/scripts/lib/ptxd_make_get.sh
index 2bac978..33b76c2 100644
--- a/scripts/lib/ptxd_make_get.sh
+++ b/scripts/lib/ptxd_make_get.sh
@@ -265,7 +265,7 @@ ptxd_make_get_svn() {
 	lmtime=$(svn info -r ${rev} "${mirror}" | \
 		awk '/^Last Changed Date:/ {print $4 " " $5 " " $6}') &&
 	echo "${PROMPT}svn: last modification time '${lmtime}'" &&
-	tar --exclude-vcs --show-stored-names ${tarcomp} \
+	GZIP=-n tar --exclude-vcs --show-stored-names ${tarcomp} \
 		--mtime="${lmtime}" --transform "s|^\.|${prefix}|g" \
 		--create --file "${path}" -C "${mirror}" .
 	ptxd_make_serialize_put
-- 
1.9.1


_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de

                 reply	other threads:[~2017-03-29 10:35 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1490783727-31494-1-git-send-email-guille.rodriguez@gmail.com \
    --to=guille.rodriguez@gmail.com \
    --cc=ptxdist@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox