[Reproducible-commits] [texlive-bin] 01/02: Restart from TL2016, only one patch to set the default value of SOURCE_DATE_EPOCH_TEX_PRIMITIVES to 1
Alexis Bienvenüe
jboulix-guest at moszumanska.debian.org
Thu May 19 14:01:46 UTC 2016
This is an automated email from the git hooks/post-receive script.
jboulix-guest pushed a commit to branch pu/reproducible_builds
in repository texlive-bin.
commit c6dede514f6c724228ad6bbaa90531b27e78f1eb
Author: Alexis Bienvenüe <pado at passoire.fr>
Date: Fri May 13 14:56:46 2016 +0200
Restart from TL2016, only one patch to set the default value of SOURCE_DATE_EPOCH_TEX_PRIMITIVES to 1
---
debian/changelog | 6 +++
debian/patches/series | 1 +
.../source-date-epoch-tex-primitives-defaults-to-1 | 54 ++++++++++++++++++++++
3 files changed, 61 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index fdb91a4..c36b2cc 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+texlive-bin (2016.20160513.41080-2.0~reproducible1) UNRELEASED; urgency=medium
+
+ * set default value of SOURCE_DATE_EPOCH_TEX_PRIMITIVES to 1
+
+ -- Alexis Bienvenüe <pado at passoire.fr> Sat, 14 May 2016 10:18:03 +0200
+
texlive-bin (2016.20160513.41080-2) unstable; urgency=medium
* uniform luajit options
diff --git a/debian/patches/series b/debian/patches/series
index 7c96ee5..66b7c8a 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -16,3 +16,4 @@ fix-mktexlsr-bashims
upupstream-xdvi-desktop-file
source-date-epoch-extension
#dvipdfmx-cidtype2-fixes
+source-date-epoch-tex-primitives-defaults-to-1
diff --git a/debian/patches/source-date-epoch-tex-primitives-defaults-to-1 b/debian/patches/source-date-epoch-tex-primitives-defaults-to-1
new file mode 100644
index 0000000..278764b
--- /dev/null
+++ b/debian/patches/source-date-epoch-tex-primitives-defaults-to-1
@@ -0,0 +1,54 @@
+Description: SOURCE_DATE_EPOCH_TEX_PRIMITIVES defaults to 1
+ If SOURCE_DATE_EPOCH is set, the tex primitives \year, \month, \day, \time
+ will be set from its value if SOURCE_DATE_EPOCH_TEX_PRIMITIVES is not set
+ or if SOURCE_DATE_EPOCH_TEX_PRIMITIVES is set to 1.
+ This helps to make reproducible builds using only the environment variable
+ SOURCE_DATE_EPOCH - setting some more *tool-specific* environment variables
+ from dpkg-buildpackage is not possible.
+Author: Alexis Bienvenüe <pado at passoire.fr>
+
+--- texlive-bin-2016.20160512.41045.orig/texk/web2c/lib/texmfmp.c
++++ texlive-bin-2016.20160512.41045/texk/web2c/lib/texmfmp.c
+@@ -2248,7 +2248,14 @@ get_date_and_time (integer *minutes, in
+ struct tm *tmptr;
+ #ifndef onlyTeX
+ string sde_texprim = getenv ("SOURCE_DATE_EPOCH_TEX_PRIMITIVES");
+- if (sde_texprim && STREQ (sde_texprim, "1")) {
++ /* warn if they gave an invalid value, empty (null string) ok. */
++ if (sde_texprim && strlen (sde_texprim) > 0
++ && !STREQ (sde_texprim, "0") && !STREQ (sde_texprim, "1")) {
++ WARNING1 ("invalid value (expected 0 or 1) for environment variable $SOURCE_DATE_EPOCH_TEX_PRIMITIVES: %s",
++ sde_texprim);
++ }
++ if (getenv ("SOURCE_DATE_EPOCH") &&
++ !(sde_texprim && STREQ (sde_texprim, "0"))) {
+ init_start_time ();
+ tmptr = gmtime (&start_time);
+ } else
+@@ -2258,15 +2265,6 @@ get_date_and_time (integer *minutes, in
+ use current time. */
+ time_t myclock = time ((time_t *) 0);
+ tmptr = localtime (&myclock);
+-
+-#ifndef onlyTeX
+- /* warn if they gave an invalid value, empty (null string) ok. */
+- if (sde_texprim && strlen (sde_texprim) > 0
+- && !STREQ (sde_texprim, "0")) {
+-WARNING1 ("invalid value (expected 0 or 1) for environment variable $SOURCE_DATE_EPOCH_TEX_PRIMITIVES: %s",
+- sde_texprim);
+- }
+-#endif /* not onlyTeX */
+ }
+
+ *minutes = tmptr->tm_hour * 60 + tmptr->tm_min;
+--- texlive-bin-2016.20160512.41045.orig/texk/web2c/man/pdftex.man
++++ texlive-bin-2016.20160512.41045/texk/web2c/man/pdftex.man
+@@ -380,7 +380,7 @@ timestamps in the PDF output, such as th
+ This is useful for making reproducible builds.
+ .TP
+ .B SOURCE_DATE_EPOCH_TEX_PRIMITIVES
+-If set to the value "1", the time-related \*(TX primitives
++If not set to the value "0", the time-related \*(TX primitives
+ .RI ( \eyear ,
+ .IR \emonth ,
+ .IR \eday ,
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/texlive-bin.git
More information about the Reproducible-commits
mailing list