Your message dated Tue, 29 Dec 2020 01:49:09 +0000
with message-id <e1ku48l-00032j...@fasolo.debian.org>
and subject line Bug#978499: fixed in fop 1:2.5-2
has caused the Debian Bug report #978499,
regarding fop: reproducible builds: Support using SOURCE_DATE_EPOCH for 
timestamps in PDF files
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 ow...@bugs.debian.org
immediately.)


-- 
978499: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=978499
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: fop
Severity: normal
Tags: patch
User: reproducible-bui...@lists.alioth.debian.org
Usertags: timestamps toolchain
X-Debbugs-Cc: reproducible-b...@lists.alioth.debian.org

Several packages use fop to generate PDF files in Debian packages, but
the resulting PDF files have embedding timestamp information in the
CreationDate of the PDF:

  
https://tests.reproducible-builds.org/debian/issues/unstable/timestamps_in_pdf_generated_by_apache_fop_issue.html


For example, in xorg-docs:

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

  /usr/share/doc/xorg-docs/xlfd/xlfd.pdf.gz
  
  CreationDate:·"D:20201225182038-12'00'"
  vs.
  CreationDate:·"D:20220129025203+14'00'"


The attached patch fixes this by adding support for the
SOURCE_DATE_EPOCH environment variable to fop, which embeds the
specified timestamp rather than the current time:

  https://reproducible-builds.org/docs/source-date-epoch/


Thanks for maintaining fop!


live well,
  vagrant
From 25826ea9c86d01a8392cf593b9aa93c72b469b19 Mon Sep 17 00:00:00 2001
From: Vagrant Cascadian <vagr...@reproducible-builds.org>
Date: Mon, 28 Dec 2020 02:48:21 +0000
Subject: [PATCH] PDFInfo.java: Support SOURCE_DATE_EPOCH environment variable.

https://reproducible-builds.org/docs/source-date-epoch/
---
 fop-core/src/main/java/org/apache/fop/pdf/PDFInfo.java | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/fop-core/src/main/java/org/apache/fop/pdf/PDFInfo.java b/fop-core/src/main/java/org/apache/fop/pdf/PDFInfo.java
index 3aa5d97..79f3f42 100644
--- a/fop-core/src/main/java/org/apache/fop/pdf/PDFInfo.java
+++ b/fop-core/src/main/java/org/apache/fop/pdf/PDFInfo.java
@@ -305,7 +305,14 @@ public class PDFInfo extends PDFObject {
      * @return the requested String representation
      */
     protected static String formatDateTime(final Date time) {
-        return formatDateTime(time, TimeZone.getDefault());
+        // https://reproducible-builds.org/docs/source-date-epoch/
+        String source_date_epoch = System.getenv("SOURCE_DATE_EPOCH");
+        if (source_date_epoch != null) {
+            Long sourcedate = (1000 * Long.parseLong(source_date_epoch));
+            return formatDateTime(new Date(sourcedate), TimeZone.getTimeZone("Etc/UTC"));
+        } else {
+            return formatDateTime(time, TimeZone.getDefault());
+        }
     }
 
     /**
-- 
2.20.1

Attachment: signature.asc
Description: PGP signature


--- End Message ---
--- Begin Message ---
Source: fop
Source-Version: 1:2.5-2
Done: tony mancill <tmanc...@debian.org>

We believe that the bug you reported is fixed in the latest version of
fop, 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 978...@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
tony mancill <tmanc...@debian.org> (supplier of updated fop 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 ftpmas...@ftp-master.debian.org)


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

Format: 1.8
Date: Mon, 28 Dec 2020 11:42:20 -0800
Source: fop
Architecture: source
Version: 1:2.5-2
Distribution: unstable
Urgency: medium
Maintainer: Debian Java Maintainers 
<pkg-java-maintain...@lists.alioth.debian.org>
Changed-By: tony mancill <tmanc...@debian.org>
Closes: 978499
Changes:
 fop (1:2.5-2) unstable; urgency=medium
 .
   * Team upload
   * Use SOURCE_DATE_EPOCH from system environment (Closes: #978499)
     For reproducible builds of packages that use fop as a build-dep.
   * Remove deprecated get-orig-source target
   * Update debian/watch to version 4
   * Bump Standards-Version to 4.5.1
   * Set Rules-Requires-Root: no in debian/control
   * Use debhelper-compat 13
Checksums-Sha1:
 d968e1726e911fcf64f60cdcdff1b8bcfecc4c3d 2609 fop_2.5-2.dsc
 7fc9a28b24bfbc47b3d92323863fc1f3df12c41e 872680 fop_2.5-2.debian.tar.xz
 8711780cff10e8078d33b386bfce8da9602beaca 13562 fop_2.5-2_amd64.buildinfo
Checksums-Sha256:
 5c9b8cbfe28d2f6e4862b85283ecac81b49f076687e3361ee940948ca55bcb66 2609 
fop_2.5-2.dsc
 0e832d792bb51e985730893e713638cd1bc7855c55607224724c4573b6f6f0a0 872680 
fop_2.5-2.debian.tar.xz
 69943af7d972a6e9333ca3716e114023eef4e94cec24dc9526acc22e1c89915c 13562 
fop_2.5-2_amd64.buildinfo
Files:
 ef9d9bb1e163758ce076c62ab5b68e9c 2609 text optional fop_2.5-2.dsc
 438823ef60f8149e1013cc13e7f0a6b4 872680 text optional fop_2.5-2.debian.tar.xz
 7e2f15de7898622a36ac6ca0b3aa3d55 13562 text optional fop_2.5-2_amd64.buildinfo

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

iQJIBAEBCgAyFiEE5Qr9Va3SequXFjqLIdIFiZdLPpYFAl/qhpcUHHRtYW5jaWxs
QGRlYmlhbi5vcmcACgkQIdIFiZdLPpbPpA//dYtYIvugoLzh0zpYshDKjvVpLB0V
4aPJAOGOZ85hbPVsPaY7CnmNtA3BRi0AjEXqggORKsS4K4XJiBJyVT1A+5rlxcU1
XGGuT2CNMrfrdFMdR8AjmG8dPuquapni4rA583FXad/TfbXwS8eqkb4FL1aiyJyi
S20XpPMs3IMqeriiVesxGnLAUp0rmwuKsj51ZLW+STHb1Bk07cqxXkAUWpu5O0aQ
WPipX+ErjgjqXdAXegqoln3LjjaxSjwx0nhg5icryOTSKXmp2ho8iwNi3ue1VR90
vBtMK/oZApVxkC5I4kZtjoaemnPrevHGHz7DO5RogYS5OJKHIUNA0Lkl0xkpKXwe
36xJzFS30cSGnHYj21nKRFGbiufv868su5yRAis/DOt8ok/ZBlj6vvYSdhNMbvLe
aNrzCHZaETDEBVMPrYByYpnvLZc23iksJbYOjQBmBigcgcc2aAxSTCataMvYZoRM
CpVCNnHpBCGtDyAYoPlMsx4K0nkQ4Qmm3ea6wr6T0Xx4E+/qDlL+1geBt5K6FXRE
4UZfBMeLixWQnd6MXGH/a6UsQ8Dn9deX7whne7wBRwSJtOP6RIX3ptwaFBZR939V
TfvQ+cMNKduliiuYcakx48uJe/fo+owgQCQVPx2xE3Iy3OcAXTV0xANWucJGPvv/
JVrGNyX3BkB4DHw=
=PHv/
-----END PGP SIGNATURE-----

--- End Message ---
__
This is the maintainer address of Debian's Java team
<https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-java-maintainers>.
 Please use
debian-j...@lists.debian.org for discussions and questions.

Reply via email to