[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#978610: a2ps: reproducible builds: Embeds build time README and info page



Package: a2ps
Severity: normal
Tags: patch
User: reproducible-builds@lists.alioth.debian.org
Usertags: timestamps
X-Debbugs-Cc: reproducible-bugs@lists.alioth.debian.org

The README and a2ps embed the build time:

  https://tests.reproducible-builds.org/debian/rb-pkg/bullseye/amd64/diffoscope-results/a2ps.html

  README
  Mon·Nov·30·21:05:05·-12·2020
  vs.
  Tue·Jan··4·05:31:47·+14·2022


The attached patches fix this by passing arguments to date to support
SOURCE_DATE_EPOCH and by removing the UPDATED calls in the .texi files
used to generate the documentation.


Thanks for maintaining a2ps!


live well,
  vagrant
From 4c7ac30978cf3d4657274e139d4b1f30155f63e2 Mon Sep 17 00:00:00 2001
From: Vagrant Cascadian <vagrant@reproducible-builds.org>
Date: Tue, 29 Dec 2020 07:16:56 +0000
Subject: [PATCH 1/6] etc/Makefile.*: Pass arguments to date to support
 SOURCE_DATE_EPOCH when generating README.

https://reproducible-builds.org/docs/source-date-epoch/
---
 etc/Makefile.am | 2 +-
 etc/Makefile.in | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/etc/Makefile.am b/etc/Makefile.am
index b0cdcac..9b75777 100644
--- a/etc/Makefile.am
+++ b/etc/Makefile.am
@@ -44,5 +44,5 @@ a2ps.cfg: a2ps_cfg Makefile
 
 # Building a time stamp to know the version.
 README: README.in Makefile
-	sed "s!@date@!`date`!g;s!@version@!$(VERSION)!g"	\
+	sed "s!@date@!`LC_ALL=C date --utc --date=@$(SOURCE_DATE_EPOCH)`!g;s!@version@!$(VERSION)!g"	\
 	$(srcdir)/README.in > README
diff --git a/etc/Makefile.in b/etc/Makefile.in
index 0fe7d4c..50af809 100644
--- a/etc/Makefile.in
+++ b/etc/Makefile.in
@@ -486,7 +486,7 @@ a2ps.cfg: a2ps_cfg Makefile
 
 # Building a time stamp to know the version.
 README: README.in Makefile
-	sed "s!@date@!`date`!g;s!@version@!$(VERSION)!g"	\
+	sed "s!@date@!`LC_ALL=C date --utc --date=@$(SOURCE_DATE_EPOCH)`!g;s!@version@!$(VERSION)!g"	\
 	$(srcdir)/README.in > README
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
-- 
2.20.1

From b21b23ae6a8e867b4941eab3486d6d940ae48f61 Mon Sep 17 00:00:00 2001
From: Vagrant Cascadian <vagrant@reproducible-builds.org>
Date: Tue, 29 Dec 2020 07:52:21 +0000
Subject: [PATCH 4/6] doc/a2ps.texi: Remove dates from generated documentation.

---
 doc/a2ps.texi | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/doc/a2ps.texi b/doc/a2ps.texi
index 5a99e8d..18c0f91 100644
--- a/doc/a2ps.texi
+++ b/doc/a2ps.texi
@@ -103,7 +103,7 @@ approved by the author.
 @titlepage
 @title GNU a2ps, version @value{VERSION}
 @subtitle General Purpose PostScript Generating Utility
-@subtitle Edition @value{EDITION}, @value{UPDATED}
+@subtitle Edition @value{EDITION}
 @author Akim Demaille
 @author Miguel Santana
 
@@ -141,8 +141,7 @@ GNU @pack{} is a filter which generates PostScript from various formats,
 with pretty-printing features, strong support for many alphabets, and
 customizable layout.
 
-This is Edition @value{VERSION} of the @pack{} documentation, updated
-@value{UPDATED}.
+This is Edition @value{VERSION} of the @pack{} documentation.
 
 @menu
 * Introduction::                Foreword
-- 
2.20.1

Attachment: signature.asc
Description: PGP signature


Reply to: