Your message dated Sun, 07 Jun 2020 17:48:30 +0000
with message-id <[email protected]>
and subject line Bug#962305: fixed in libtommath 1.2.0-4
has caused the Debian Bug report #962305,
regarding libtommath: Documentation .pdf files embed time
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
962305: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=962305
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Source: libtommath
Severity: normal
Tags: patch
User: [email protected]
Usertags: timestamps
X-Debbugs-Cc: [email protected]

When the build time and timezone vary, the resulting .pdf file includes
an embedded timestamp. It looks like doc/makefile attempts to make the
timestamp reproducible in the generated .pdf, but doesn't catch some
corner cases.

The patch to debian/rules sets FORCE_SOURCE_DATE, which is needed to get
texlive to respect SOURCE_DATE_EPOCH.

The other patch modifies doc/makefile to use SOURCE_DATE_EPOCH directly
rather than a reference timestamp file.

Thanks for maintaining libtommath!

live well,
  vagrant

From 031c52564c767985e741a6b10aeedc624544a634 Mon Sep 17 00:00:00 2001
From: Vagrant Cascadian <[email protected]>
Date: Fri, 5 Jun 2020 21:26:02 +0000
Subject: [PATCH 1/2] debian/rules: export FORCE_SOURCE_DATE to allow .pdf
 files to be generated reproducibly.

Without FORCE_SOURCE_DATE texlive does not respect SOURCE_DATE_EPOCH:

  https://reproducible-builds.org/docs/source-date-epoch/
---
 debian/rules | 1 +
 1 file changed, 1 insertion(+)

diff --git a/debian/rules b/debian/rules
index 97dbb93..b00c0b5 100755
--- a/debian/rules
+++ b/debian/rules
@@ -19,6 +19,7 @@ export PREFIX=/usr
 DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
 export LIBPATH = $(PREFIX)/lib/$(DEB_HOST_MULTIARCH)
 
+export FORCE_SOURCE_DATE=1
 
 %:
 	dh $@
-- 
2.20.1

From ef8c77d9c5fd62773b467fa6e7b1a5167c4f770b Mon Sep 17 00:00:00 2001
From: Vagrant Cascadian <[email protected]>
Date: Fri, 5 Jun 2020 21:55:05 +0000
Subject: [PATCH 2/2] Add patch to use UTC timezone for PDF generation.

---
 debian/patches/series           |  1 +
 debian/patches/use-utc-timezone | 37 +++++++++++++++++++++++++++++++++
 2 files changed, 38 insertions(+)
 create mode 100644 debian/patches/use-utc-timezone

diff --git a/debian/patches/series b/debian/patches/series
index 1652816..198b971 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
 increase-test-timeout
 remove-undefined-macro
 fix-shift-count-overflow-on-x32
+use-utc-timezone
diff --git a/debian/patches/use-utc-timezone b/debian/patches/use-utc-timezone
new file mode 100644
index 0000000..003b86f
--- /dev/null
+++ b/debian/patches/use-utc-timezone
@@ -0,0 +1,37 @@
+Author: Vagrant Cascadian <[email protected]>
+Subject: Ensure the date is represented in UTC when generating PDF
+ files.
+Description: Use SOURCE_DATE_EPOCH directly rather than a timestamp
+ reference file which can vary between builds.
+ .
+ https://reproducible-builds.org/docs/source-date-epoch/
+
+Index: libtommath/doc/makefile
+===================================================================
+--- libtommath.orig/doc/makefile
++++ libtommath/doc/makefile
+@@ -16,15 +16,12 @@ docs: manual
+ 
+ #LTM user manual
+ mandvi: bn.tex
+-	cp bn.tex bn.bak
+-	touch --reference=bn.tex bn.bak
+-	(printf "%s" "\def\fixedpdfdate{"; date +'D:%Y%m%d%H%M%S%:z' -d @$$(stat --format=%Y bn.tex) | sed "s/:\([0-9][0-9]\)$$/'\1'}/g") > bn-deterministic.tex
++	(printf "%s" "\def\fixedpdfdate{"; date +'D:%Y%m%d%H%M%S%:z' -u -d @$(SOURCE_DATE_EPOCH) | sed "s/:\([0-9][0-9]\)$$/'\1'}/g") > bn-deterministic.tex
+ 	printf "%s\n" "\pdfinfo{" >> bn-deterministic.tex
+ 	printf "%s\n" "  /CreationDate (\fixedpdfdate)" >> bn-deterministic.tex
+ 	printf "%s\n}\n" "  /ModDate (\fixedpdfdate)" >> bn-deterministic.tex
+ 	cat bn.tex >> bn-deterministic.tex
+ 	mv bn-deterministic.tex bn.tex
+-	touch --reference=bn.bak bn.tex
+ 	echo "hello" > bn.ind
+ 	latex bn ${silent_stdout}
+ 	latex bn ${silent_stdout}
+@@ -35,7 +32,6 @@ mandvi: bn.tex
+ manual:	mandvi
+ 	pdflatex bn >/dev/null
+ 	sed -b -i 's,^/ID \[.*\]$$,/ID [<0> <0>],g' bn.pdf
+-	mv bn.bak bn.tex
+ 	rm -f bn.aux bn.dvi bn.log bn.idx bn.lof bn.out bn.toc
+ 
+ clean:
-- 
2.20.1

Attachment: signature.asc
Description: PGP signature


--- End Message ---
--- Begin Message ---
Source: libtommath
Source-Version: 1.2.0-4
Done: Dominique Dumont <[email protected]>

We believe that the bug you reported is fixed in the latest version of
libtommath, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Dominique Dumont <[email protected]> (supplier of updated libtommath package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Sun, 07 Jun 2020 18:29:38 +0200
Source: libtommath
Architecture: source
Version: 1.2.0-4
Distribution: unstable
Urgency: medium
Maintainer: Debian Rakudo Maintainers <[email protected]>
Changed-By: Dominique Dumont <[email protected]>
Closes: 962305
Changes:
 libtommath (1.2.0-4) unstable; urgency=medium
 .
   * make pdf build reproducible.
     Thanks to Vagrant Cascadian for the patch (Closes: 962305)
   * control: declare compliance with poliy 4.5.0
Checksums-Sha1:
 eecd80f98fe7f6b660510b04a18c5e5a56aa6e81 2457 libtommath_1.2.0-4.dsc
 be1222e33fcc6757e9aca88cf9a025ba4338e039 20176 libtommath_1.2.0-4.debian.tar.xz
 180eb9a2ed669edcd339422856ed54bd46eb6b54 8192 
libtommath_1.2.0-4_source.buildinfo
Checksums-Sha256:
 d63abe990504e3d39dfd934006b7b19a60802e7daf008c31c7ed2b8861cd02a3 2457 
libtommath_1.2.0-4.dsc
 a49fec7e59e621ffea3211f1559efe27300c09e4c3e1a5d7388784611cdbfdc2 20176 
libtommath_1.2.0-4.debian.tar.xz
 b8dfe790721eaf49f258141ee3f3d9690e6606a13569df466bc7e2669c0c08cd 8192 
libtommath_1.2.0-4_source.buildinfo
Files:
 f2020b0d8797ff6b0a5211881cb132cf 2457 libs optional libtommath_1.2.0-4.dsc
 ae4ad1b42072c6993cb8a135e942d9f6 20176 libs optional 
libtommath_1.2.0-4.debian.tar.xz
 56c8c8bd4be44c2649530e1ec6405b8e 8192 libs optional 
libtommath_1.2.0-4_source.buildinfo

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEn3I5/LZk8Qsz6dwDwx9P2UmrK2wFAl7dJG4ACgkQwx9P2Umr
K2wY3A/+KcEH85Zav2779smqaTfb+JI3wfFcMJYjoUiGKqeUMHxZNZDwFfFwkroy
koCxKDbG8jKZ0X4gBO/BOT7XwusNC7xcBHYTe9KOXig3MT0rc1LAUDY6x1zY3PEr
LDLnxcZNcfeRf0KlpLV/h8VXKDrBude6yvBtF/wA8VO6W8vpqsXveF4bok6psKSe
2Uk+ZnBZ1x6OS4wNI6TJCOAuyE15CGzkYsf9KAIkVYM6L4g2PPtGsw46VtLfcCtE
vaiUZPwsj7U0e1XKeJcn5UV/NtQNn43vmkv822in2oS9xpiJ1crMOHl3wQjy/wXc
O7AwPoFLCB3ZBtkg0eCpxSkTClCXa3uagPXBjnKUOsXOZuPN5MOq9lt9q77rXRt6
6azfCERfKJQF5G5ch+I6HO5ohWdectbUCMlcPvZboMqsZ/mMAWBmERy9NFLuMAnx
8sfPzoukKtQZ8r474CKd1PnxUmc0urSgdjfV628TqfSru9bnZ7RVfv+uaALnWLq3
L6eXRyjdQCQJCa84ZsUDG3SO5dl9pObFurIaJVF4r2hKSRyCTmTLczS/3cD1A7e/
WzIof4sUTTa5HJoAPLVmYTaFB3F68PLDpAzT3BzXGI8RhRYROKZBbFZQqoj9Nt3X
Ak9pg68zZ6mDT/Li5Y1uDakDeL52AA7S1aSoMJaeqa9FwEg/W6Q=
=Z1Qe
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to