From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id wAvQLBhm9WD+HgAAgWs5BA (envelope-from ) for ; Mon, 19 Jul 2021 13:46:32 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id 6MalKBhm9WCAQQAAB5/wlQ (envelope-from ) for ; Mon, 19 Jul 2021 11:46:32 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id E349BF1B9 for ; Mon, 19 Jul 2021 13:46:31 +0200 (CEST) Received: from localhost ([::1]:49558 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m5RjC-0001XI-4e for larch@yhetil.org; Mon, 19 Jul 2021 07:46:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:57768) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m5Rio-0001U0-Ap for guix-patches@gnu.org; Mon, 19 Jul 2021 07:46:09 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:46636) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m5Rik-0001Jm-O0 for guix-patches@gnu.org; Mon, 19 Jul 2021 07:46:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1m5Rik-0000iq-LY for guix-patches@gnu.org; Mon, 19 Jul 2021 07:46:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#49640] [PATCH core-updates] gnu: ghostscript: Improve reproducibility of PDF document generation Resent-From: Guillaume Le Vaillant Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 19 Jul 2021 11:46:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 49640 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 49640@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.16266951292733 (code B ref -1); Mon, 19 Jul 2021 11:46:02 +0000 Received: (at submit) by debbugs.gnu.org; 19 Jul 2021 11:45:29 +0000 Received: from localhost ([127.0.0.1]:58182 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5RiD-0000i0-Bn for submit@debbugs.gnu.org; Mon, 19 Jul 2021 07:45:29 -0400 Received: from lists.gnu.org ([209.51.188.17]:35668) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5RiB-0000ht-Ux for submit@debbugs.gnu.org; Mon, 19 Jul 2021 07:45:28 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:57660) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m5Ri5-0000Tg-HP for guix-patches@gnu.org; Mon, 19 Jul 2021 07:45:27 -0400 Received: from mout01.posteo.de ([185.67.36.65]:34509) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m5Rhz-0000fp-7u for guix-patches@gnu.org; Mon, 19 Jul 2021 07:45:19 -0400 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id B3154240028 for ; Mon, 19 Jul 2021 13:45:09 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1626695109; bh=LPMwDBlY38L8zh/5Mjxd3//KyxwxoqR+17ot6h2p+Ck=; h=From:To:Subject:Date:From; b=GyJPakffV1hmghkCfJ7Ff/YZGVswp9bidTtMlCn6P1egHh++lmjbgWjaOJ+8MCgRM utGpfzv2woxiAdAP4BJOrWIsc7x6pFQOHBJICDroGFRLsY7r7VdD9fKpSiW8usewRr LyhFQvAiX0tzktHHHi2oS0ZlmPzKcXZd6Lcj/Fzrki+sunGpD/8DfU9yUeUY6B9spq iHIuQJnX2EsoZAAKE30f9eaaIOlg5Ot6kTQOTTt9m0ncgb3eXGi1yNNyUolmE3pLUq pb4VXeb23yEeqLTNKKLm8EHkkzKp+N/8uM4/93NFwjzZz57/uJVN6dVfQZGcLJGrmL a27jrQH0WiiZw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4GT0QD6VwQz9rxF for ; Mon, 19 Jul 2021 13:45:08 +0200 (CEST) From: Guillaume Le Vaillant Date: Mon, 19 Jul 2021 11:45:07 +0000 Message-ID: <87eebucyt8.fsf@kitej> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Received-SPF: pass client-ip=185.67.36.65; envelope-from=glv@posteo.net; helo=mout01.posteo.de X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1626695192; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:list-id:list-help:list-unsubscribe:list-subscribe: list-post:dkim-signature; bh=LFju5zUB8LNKdqCTEqM6zwOYMvl3oUJ5WM39mql4hUY=; b=LtSCmmJgrOkTqhCuw+amfmTmAmz6a7hA4kjZ5WI6LO7rgqV+ABEcpmqspGsTsfbyehKTjG 7Otj2szxcI1DUncwAw7yAK7xmmnNI9FCLlsgRnEqkth5YEoJp1/2oPXOiai/m6YzTjpJj6 pzlVg0BxmuLYqILSnE6znXiDIyBEcWDDemRrHqvX7u1+PZn5qe0OJKf6+6P08R8MazvQ36 3XcDjjKnIQevedwa/VgN4UeLmzKYC7zEPPJFJ8F4rxoyP+H8ocN6HkwmwplkZaBklTGV51 2cxdg8gTzqMALFGqWQV/smeLQvRTzgUIRX4yMUsPNTiDM9RAesHUmBqwyxpJjA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1626695192; a=rsa-sha256; cv=none; b=L7V0R/3+QwR8Au7GIctOk5NIKS5zmty2oacle5X3+tUff50xYVl/ntMBUsmcGWW/uazIuu NZG0QkQLtnU5bWe32zSaiw4tJ2JUVykfZIWYAWK56ep8GxS1kKoMQ7vPOxUujLf8zqc6Wc qKCmlHrKSbi/ldmcFg3kHc1u/hhXxz3R+2Y+c+Jmntqmr6naTi00ICh6O1jXJUOf/4YDi3 Q4J2R+QBMrIQYMC4Lru1zy0wAuU67wtKDqnYSHAjsNel6vU/mzv8oFXb+xQovlReXgN6Iq L5o1JgjNAw0XJHGMbpBl5INEEVnXgPhxbwG2AwcnDcjWKa4pRMmPEfcjqvJzoA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=posteo.net header.s=2017 header.b=GyJPakff; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.net (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -2.91 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=posteo.net header.s=2017 header.b=GyJPakff; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.net (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: E349BF1B9 X-Spam-Score: -2.91 X-Migadu-Scanner: scn0.migadu.com X-TUID: w5O/ElCVrM6A --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: text/plain Hi, When trying to solve a reproducibility issue when generating the PDF documentation of the txr software (see [1]), Paul Patience noticed that ghostscript writes a creation date in the PDF even when the GS_GENERATE_UUIDS environment variable is set to "0". The attached patch updates 'ghostscript-no-header-creationdate.patch' to fix this issue. Given the amount of rebuilds caused by modifying ghostscript, this should go to core-updates, but is core-updates in freeze state already, or can I push this patch right now? Note: Even with this patch, there are still some cases where PDF generation by ghostscript is not reproducible (for reasons not related to creation date), like groff-doc. [1]: https://bugs.gnu.org/49517 --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-gnu-ghostscript-Improve-reproducibility-of-PDF-docum.patch Content-Transfer-Encoding: quoted-printable From=20db5962c68099f835350c24c8a3f889b9fa1f8a8e Mon Sep 17 00:00:00 2001 From: Guillaume Le Vaillant Date: Mon, 19 Jul 2021 11:48:12 +0200 Subject: [PATCH] gnu: ghostscript: Improve reproducibility of PDF document generation * gnu/packages/patches/ghostscript-no-header-creationdate.patch: Disable writing "xmp:ModifyDate" and "xmp:CreateDate" if GS_GENERATE_UUIDS is set= to "0" or "no". =2D-- .../ghostscript-no-header-creationdate.patch | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/patches/ghostscript-no-header-creationdate.patch = b/gnu/packages/patches/ghostscript-no-header-creationdate.patch index 92ddbdade0..b19f3ab5d9 100644 =2D-- a/gnu/packages/patches/ghostscript-no-header-creationdate.patch +++ b/gnu/packages/patches/ghostscript-no-header-creationdate.patch @@ -20,3 +20,25 @@ index 0fb067e..b342e2c 100644 { struct tm tms; time_t t; +--- orig/gnu-ghostscript-9.14.0/devices/vector/gdevpdfe.c ++++ gnu-ghostscript-9.14.0/devices/vector/gdevpdfe.c +@@ -692,6 +692,9 @@ + pdf_xml_attribute_name(s, "xmlns:xmp"); + pdf_xml_attribute_value(s, "http://ns.adobe.com/xap/1.0/"); + pdf_xml_tag_end(s); ++ if (!getenv("GS_GENERATE_UUIDS") || ++ (strcasecmp(getenv("GS_GENERATE_UUIDS"), "0") !=3D 0 && ++ strcasecmp(getenv("GS_GENERATE_UUIDS"), "no") !=3D 0)) + { + pdf_xml_tag_open_beg(s, "xmp:ModifyDate"); + pdf_xml_tag_end(s); +@@ -700,6 +701,9 @@ + pdf_xml_tag_close(s, "xmp:ModifyDate"); + pdf_xml_newline(s); + } ++ if (!getenv("GS_GENERATE_UUIDS") || ++ (strcasecmp(getenv("GS_GENERATE_UUIDS"), "0") !=3D 0 && ++ strcasecmp(getenv("GS_GENERATE_UUIDS"), "no") !=3D 0)) + { + pdf_xml_tag_open_beg(s, "xmp:CreateDate"); + pdf_xml_tag_end(s); =2D-=20 2.32.0 --=-=-=-- --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iIUEAREKAC0WIQTLxZxm7Ce5cXlAaz5r6CCK3yH+PwUCYPVlww8cZ2x2QHBvc3Rl by5uZXQACgkQa+ggit8h/j+F/wD+LW+8WvWlSI0/4+k3Pack6bYVbOwyOmGAkLd6 K91UgCQA/iveL5MRM5d1cHaZElkypnwjczvG6BT+nmTVPJkZ6pr+ =ngON -----END PGP SIGNATURE----- --==-=-=--