GNU bug report logs - #56893
rust-vergen inserts build timestamps, possible irreproducibility source

Previous Next

Package: guix;

Reported by: Maxime Devos <maximedevos <at> telenet.be>

Date: Tue, 2 Aug 2022 16:59:01 UTC

Severity: normal

Full log


View this message in rfc822 format

From: Fabian Grünbichler <f.gruenbichler <at> proxmox.com>
To: 1016546 <at> bugs.debian.org, 56893 <at> debbugs.gnu.org, Maxime Devos <maximedevos <at> telenet.be>
Subject: bug#56893: [Pkg-rust-maintainers] Bug#1016546: rust-vergen inserts build timestamps
Date: Wed, 03 Aug 2022 09:09:54 +0200
On August 2, 2022 10:16 pm, Maxime Devos wrote:
> On 02-08-2022 20:41, Geert Stappers wrote:
> 
>> Date: Tue, 2 Aug 2022 19:18:46 +0200, From: Maxime Devos
>>> In Guix, I've noticed that rust-vergen embeds build timestamps. There is also
>>> a work-around available: <https://issues.guix.gnu.org/56893#1>.
>>   
>>
>> Thanks for reporting the FTBR.
>>
>> Please update the workaround, so it looks more
>> like https://en.wikipedia.org/wiki/Diff#Unified_format
>> and can be absured by https://en.wikipedia.org/wiki/Patch_(Unix)
>>
>>
>> Just telling the filename that needs modification would be a great help.
> 
> Oops, I did not send the full work-around, here it is:
> 
>>          (substitute* (find-files "." "\\.rs$")
>>            (("^extern crate chrono;") "extern crate chrono; use 
>> chrono::Utc; use chrono::TimeZone;")
>>            (("^use chrono::Utc;") "use chrono::Utc; use 
>> chrono::TimeZone;")
>>            (("\\bUtc::now\\(\\)") "Utc.timestamp(0, 0)"))))))
> (Should hopefully be clearer now!)
> 
> The important thing here is replacing all instances of Utc::now() 
> (across all Rust source files of rust-vergen) by Utc.timestamp(0, 0), 
> the rest is just adding the required imports -- I have not made a list 
> of all file names.  If you want a list, try "grep -rF Utc::now" or such.
> 
> I do not intend to update the workaround, it works fine in Guix and 
> frankly porting it to whatever format Debian likes is Debian's concern, 
> not Guix', I'm just sharing our workaround as a courtesy to another distro.

also note that for debian purposes, we likely want to honor 
SOURCE_DATE_EPOCH instead of setting it to epoch zero.





This bug report was last modified 2 years and 321 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.