summaryrefslogtreecommitdiff
path: root/debian/patches/etcmakefile.-pass-arguments-to-date-to-s.patch
blob: 08f0ff9250f91e7695e22cc31bd02bc68b6b0c65 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
From: Vagrant Cascadian <vagrant@reproducible-builds.org>
Date: Tue, 29 Dec 2020 07:16:56 +0000
X-Dgit-Generated: 1:4.14-6 ef7606529df04df6daf9bcd6b67dd3ee1fdef7b1
Subject: etc/Makefile.*: Pass arguments to date to support SOURCE_DATE_EPOCH when generating README. (Closes: #978610)


---

--- a2ps-4.14.orig/etc/Makefile.am
+++ a2ps-4.14/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
--- a2ps-4.14.orig/etc/Makefile.in
+++ a2ps-4.14/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.