gnu: emacs-consult: Fix grammar.
[jackhill/guix/guix.git] / gnu / packages / patches / perl-reproducible-build-date.patch
CommitLineData
a3d6e1f4
LF
1Don't encode the current timestamp.
2
3This affects the output of `perl -V`, specifically the message "Compiled
4at [...]".
5
5bde2968
LC
6The 'cf_time' and 'cf_by' values show up in 'config.h' and
7in 'Config_heavy.pl'.
8
9Use the output of 'uname -s' instead of 'uname -a' to avoid recording
10the kernel version ('uname -o' leads to directory names like
11'x86_64-gnulinux' instead of 'x86_64-linux', which might cause breakage
12down the road.)
13
a3d6e1f4
LF
14diff --git a/perl.c b/perl.c
15index 228a0d8..ed38313 100644
16--- a/perl.c
17+++ b/perl.c
18@@ -1825,6 +1825,7 @@ S_Internals_V(pTHX_ CV *cv)
19 PUSHs(Perl_newSVpvn_flags(aTHX_ non_bincompat_options,
20 sizeof(non_bincompat_options) - 1, SVs_TEMP));
21
22+#define PERL_BUILD_DATE "Jan 1 1970 00:00:00"
23 #ifndef PERL_BUILD_DATE
24 # ifdef __DATE__
25 # ifdef __TIME__
5bde2968
LC
26
27--- a/Configure 1970-01-01 01:00:00.000000000 +0100
28+++ b/Configure 2016-10-01 14:47:20.017319739 +0200
29@@ -3276,7 +3276,7 @@ $eunicefix tr
30 : Try to determine whether config.sh was made on this system
31 case "$config_sh" in
32 '')
33-myuname=`$uname -a 2>/dev/null`
34+myuname=`$uname -s 2>/dev/null`
35 $test -z "$myuname" && myuname=`hostname 2>/dev/null`
36 # Downcase everything to avoid ambiguity.
37 # Remove slashes and single quotes so we can use parts of this in
38@@ -3845,10 +3845,10 @@
39 . ./posthint.sh
40
41 : who configured the system
42-cf_time=`LC_ALL=C; LANGUAGE=C; export LC_ALL; export LANGUAGE; $date 2>&1`
43+cf_time="1970-01-01"
44 case "$cf_by" in
45 "")
46- cf_by=`(logname) 2>/dev/null`
47+ cf_by="guix"
48 case "$cf_by" in
49 "")
50 cf_by=`(whoami) 2>/dev/null`