Debian Bug report logs - #828683
mc: please make the build reproducible

version graph

Package: src:mc; Maintainer for src:mc is Dmitry Smirnov <onlyjob@debian.org>;

Reported by: Reiner Herrmann <reiner@reiner-h.de>

Date: Sun, 26 Jun 2016 18:45:02 UTC

Severity: wishlist

Tags: patch

Found in version mc/3:4.8.17-1

Fixed in version mc/3:4.8.28-1.1

Done: Vagrant Cascadian <vagrant@reproducible-builds.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, reproducible-builds@lists.alioth.debian.org, Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>:
Bug#828683; Package src:mc. (Sun, 26 Jun 2016 18:45:06 GMT) (full text, mbox, link).


Acknowledgement sent to Reiner Herrmann <reiner@reiner-h.de>:
New Bug report received and forwarded. Copy sent to reproducible-builds@lists.alioth.debian.org, Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>. (Sun, 26 Jun 2016 18:45:06 GMT) (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: Reiner Herrmann <reiner@reiner-h.de>
To: submit@bugs.debian.org
Subject: mc: please make the build reproducible
Date: Sun, 26 Jun 2016 20:43:03 +0200
[Message part 1 (text/plain, inline)]
Source: mc
Version: 3:4.8.17-1
Severity: wishlist
Tags: patch
User: reproducible-builds@lists.alioth.debian.org
Usertags: timestamps
X-Debbugs-Cc: reproducible-builds@lists.alioth.debian.org

Hi!

While working on the "reproducible builds" effort [1], we have noticed
that mc could not be built reproducibly.
It embeds the current date into the mcedit manpage during build.

The attached patch uses SOURCE_DATE_EPOCH as a deterministic
timestamp instead.

Regards,
 Reiner

[1]: https://wiki.debian.org/ReproducibleBuilds
[mc.patch (text/x-diff, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>:
Bug#828683; Package src:mc. (Sun, 26 Jun 2016 19:09:06 GMT) (full text, mbox, link).


Acknowledgement sent to Reiner Herrmann <reiner@reiner-h.de>:
Extra info received and forwarded to list. Copy sent to Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>. (Sun, 26 Jun 2016 19:09:06 GMT) (full text, mbox, link).


Message #10 received at 828683@bugs.debian.org (full text, mbox, reply):

From: Reiner Herrmann <reiner@reiner-h.de>
To: "Yury V. Zaytsev" <yury@shurup.com>
Cc: 828683@bugs.debian.org, reproducible-builds@lists.alioth.debian.org
Subject: Re: [Pkg-mc-devel] Bug#828683: mc: please make the build reproducible
Date: Sun, 26 Jun 2016 21:06:40 +0200
[Message part 1 (text/plain, inline)]
On Sun, Jun 26, 2016 at 09:00:50PM +0200, Yury V. Zaytsev wrote:
> >The attached patch uses SOURCE_DATE_EPOCH as a deterministic timestamp
> >instead.
> 
> I wouldn't mind upstreaming this patch as long as SOURCE_DATE_EPOCH is at
> least halfway standardized. Could you please tell me whether this is
> Debian-specific, or other distros are also adopting this convention?

Thanks for intending to upstream it!
Yes, it is standardized [1] and already supported by a lot of build
tools [2], e.g. even by gcc.
Other distributions and FreeBSD are currently also in the process of
adopting it.

[1]: https://reproducible-builds.org/specs/source-date-epoch/
[2]: https://wiki.debian.org/ReproducibleBuilds/TimestampsProposal#Reading_the_variable
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>:
Bug#828683; Package src:mc. (Sun, 26 Jun 2016 19:09:08 GMT) (full text, mbox, link).


Acknowledgement sent to "Yury V. Zaytsev" <yury@shurup.com>:
Extra info received and forwarded to list. Copy sent to Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>. (Sun, 26 Jun 2016 19:09:08 GMT) (full text, mbox, link).


Message #15 received at 828683@bugs.debian.org (full text, mbox, reply):

From: "Yury V. Zaytsev" <yury@shurup.com>
To: Reiner Herrmann <reiner@reiner-h.de>, 828683@bugs.debian.org
Cc: reproducible-builds@lists.alioth.debian.org
Subject: Re: [Pkg-mc-devel] Bug#828683: mc: please make the build reproducible
Date: Sun, 26 Jun 2016 21:00:50 +0200 (CEST)
Hi Reiner,

On Sun, 26 Jun 2016, Reiner Herrmann wrote:

> While working on the "reproducible builds" effort [1], we have noticed 
> that mc could not be built reproducibly. It embeds the current date into 
> the mcedit manpage during build.

That's my fault: the dates were originally entered by hand, which, of 
course, soon enough resulted in that they were no longer current, so I 
campaigned for them to be set automatically during the build.

> The attached patch uses SOURCE_DATE_EPOCH as a deterministic timestamp 
> instead.

I wouldn't mind upstreaming this patch as long as SOURCE_DATE_EPOCH is at 
least halfway standardized. Could you please tell me whether this is 
Debian-specific, or other distros are also adopting this convention?

Many thanks!

-- 
Sincerely yours,
Yury V. Zaytsev



Information forwarded to debian-bugs-dist@lists.debian.org, Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>:
Bug#828683; Package src:mc. (Sun, 26 Jun 2016 20:15:16 GMT) (full text, mbox, link).


Acknowledgement sent to "Yury V. Zaytsev" <yury@shurup.com>:
Extra info received and forwarded to list. Copy sent to Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>. (Sun, 26 Jun 2016 20:15:16 GMT) (full text, mbox, link).


Message #20 received at 828683@bugs.debian.org (full text, mbox, reply):

From: "Yury V. Zaytsev" <yury@shurup.com>
To: Reiner Herrmann <reiner@reiner-h.de>
Cc: 828683@bugs.debian.org, reproducible-builds@lists.alioth.debian.org
Subject: Re: [Pkg-mc-devel] Bug#828683: mc: please make the build reproducible
Date: Sun, 26 Jun 2016 22:09:36 +0200 (CEST)
Hi Reiner,

On Sun, 26 Jun 2016, Reiner Herrmann wrote:

> Yes, it is standardized [1] and already supported by a lot of build 
> tools [2], e.g. even by gcc. Other distributions and FreeBSD are 
> currently also in the process of adopting it.

Thank you for the clarifications! Maybe you could consider including these 
links in the original reports to mitigate such follow-up questions...

I've had a look at our build system, and my impression is that your patch 
should not be necessary. Please have a look at

    doc/man/date-of-man-include.am

and in particular at MAN_DATE_CMD variable and following targets.

It encodes mtime of the source man file in the output, rather than the 
build date, so, as long as the source date is not modified, the build 
should be reproducible.

I believe that the lines that you have patched are currently unused and 
should be simply removed.

Am I missing something?

-- 
Sincerely yours,
Yury V. Zaytsev



Information forwarded to debian-bugs-dist@lists.debian.org, Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>:
Bug#828683; Package src:mc. (Sun, 26 Jun 2016 20:27:08 GMT) (full text, mbox, link).


Acknowledgement sent to "Yury V. Zaytsev" <yury@shurup.com>:
Extra info received and forwarded to list. Copy sent to Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>. (Sun, 26 Jun 2016 20:27:08 GMT) (full text, mbox, link).


Message #25 received at 828683@bugs.debian.org (full text, mbox, reply):

From: "Yury V. Zaytsev" <yury@shurup.com>
To: Reiner Herrmann <reiner@reiner-h.de>, 828683@bugs.debian.org
Cc: reproducible-builds@lists.alioth.debian.org
Subject: Re: [Pkg-mc-devel] Bug#828683: mc: please make the build reproducible
Date: Sun, 26 Jun 2016 22:21:49 +0200 (CEST)
On Sun, 26 Jun 2016, Reiner Herrmann wrote:

> While working on the "reproducible builds" effort [1], we have noticed 
> that mc could not be built reproducibly. It embeds the current date into 
> the mcedit manpage during build.

Ok, I think that I can now see what went wrong here: Debian used to patch 
mcedit manpage, and so, mtime of the manpage file was set to the current 
time during the build. Our build system faithfully hardcoded this into the 
resulting man file.

Since then, however, I've upstreamed the patch and it was removed from 
3:4.8.17-1, so I'm really wondering why it is still not working for you...

-- 
Sincerely yours,
Yury V. Zaytsev



Information forwarded to debian-bugs-dist@lists.debian.org, Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>:
Bug#828683; Package src:mc. (Mon, 27 Jun 2016 08:27:06 GMT) (full text, mbox, link).


Acknowledgement sent to Reiner Herrmann <reiner@reiner-h.de>:
Extra info received and forwarded to list. Copy sent to Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>. (Mon, 27 Jun 2016 08:27:06 GMT) (full text, mbox, link).


Message #30 received at 828683@bugs.debian.org (full text, mbox, reply):

From: Reiner Herrmann <reiner@reiner-h.de>
To: "Yury V. Zaytsev" <yury@shurup.com>
Cc: 828683@bugs.debian.org, reproducible-builds@lists.alioth.debian.org
Subject: Re: [Pkg-mc-devel] Bug#828683: mc: please make the build reproducible
Date: Mon, 27 Jun 2016 10:24:00 +0200
[Message part 1 (text/plain, inline)]
On Sun, Jun 26, 2016 at 10:21:49PM +0200, Yury V. Zaytsev wrote:
> On Sun, 26 Jun 2016, Reiner Herrmann wrote:
> 
> >While working on the "reproducible builds" effort [1], we have noticed
> >that mc could not be built reproducibly. It embeds the current date into
> >the mcedit manpage during build.
> 
> Ok, I think that I can now see what went wrong here: Debian used to patch
> mcedit manpage, and so, mtime of the manpage file was set to the current
> time during the build. Our build system faithfully hardcoded this into the
> resulting man file.
> 
> Since then, however, I've upstreamed the patch and it was removed from
> 3:4.8.17-1, so I'm really wondering why it is still not working for you...

You are right, the mtime of the file is used for the manpage timestamp.
But there is still a patch modifying the manpage: mcedit_full_path.patch.
When this patch is upstreamed, the SOURCE_DATE_EPOCH patch is not needed,
though it would still help when the manpages are patched.
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>:
Bug#828683; Package src:mc. (Mon, 27 Jun 2016 08:45:03 GMT) (full text, mbox, link).


Acknowledgement sent to "Yury V. Zaytsev" <yury@shurup.com>:
Extra info received and forwarded to list. Copy sent to Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>. (Mon, 27 Jun 2016 08:45:03 GMT) (full text, mbox, link).


Message #35 received at 828683@bugs.debian.org (full text, mbox, reply):

From: "Yury V. Zaytsev" <yury@shurup.com>
To: Reiner Herrmann <reiner@reiner-h.de>
Cc: 828683@bugs.debian.org, reproducible-builds@lists.alioth.debian.org
Subject: Re: [Pkg-mc-devel] Bug#828683: mc: please make the build reproducible
Date: Mon, 27 Jun 2016 10:39:52 +0200 (CEST)
Hi Reiner,

On Mon, 27 Jun 2016, Reiner Herrmann wrote:

> You are right, the mtime of the file is used for the manpage timestamp. 
> But there is still a patch modifying the manpage: 
> mcedit_full_path.patch. When this patch is upstreamed, the 
> SOURCE_DATE_EPOCH patch is not needed, though it would still help when 
> the manpages are patched.

Thank you for the confirmation that my guesses are correct!

However, I'm hesitant to apply SOURCE_DATE_EPOCH to anything that looks 
like a nail. I believe that patching of upstream sources by Debian is such 
an oft occurring situation, that I would rather look for at solution at 
the packaging level. After all, builds from *upstream* sources are 
*already* reproducible, in this case, it's the Debian build procedure that 
is injecting randomness here.

For instance, it seems to me that it is only logical to set the mtime of 
patched files to the mtime of the last patch that touched them, and this 
will make the source mtime dependent builds fully reproducible.

Have you already thought of that, and if yes, what are the counter 
arguments against this approach?

-- 
Sincerely yours,
Yury V. Zaytsev



Information forwarded to debian-bugs-dist@lists.debian.org, Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>:
Bug#828683; Package src:mc. (Mon, 27 Jun 2016 13:03:06 GMT) (full text, mbox, link).


Acknowledgement sent to Reiner Herrmann <reiner@reiner-h.de>:
Extra info received and forwarded to list. Copy sent to Debian MC Packaging Group <pkg-mc-devel@lists.alioth.debian.org>. (Mon, 27 Jun 2016 13:03:06 GMT) (full text, mbox, link).


Message #40 received at 828683@bugs.debian.org (full text, mbox, reply):

From: Reiner Herrmann <reiner@reiner-h.de>
To: Reproducible Builds discussion list <reproducible-builds@lists.alioth.debian.org>
Cc: 828683@bugs.debian.org
Subject: Re: [Reproducible-builds] [Pkg-mc-devel] Bug#828683: mc: please make the build reproducible
Date: Mon, 27 Jun 2016 14:58:45 +0200
[Message part 1 (text/plain, inline)]
On Mon, Jun 27, 2016 at 10:39:52AM +0200, Yury V. Zaytsev wrote:
> For instance, it seems to me that it is only logical to set the mtime of
> patched files to the mtime of the last patch that touched them, and this
> will make the source mtime dependent builds fully reproducible.
> 
> Have you already thought of that, and if yes, what are the counter arguments
> against this approach?

Yes, we already thought of that, unfortunately there will be issues, if
the timestamp is reset after patching.

From dpkg-source(1) for 3.0 (quilt) format:

> The timestamp of all patched files is reset to the extraction time of
> the source package (this avoids timestamp skews leading to problems
> when autogenerated files are patched).
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Dmitry Smirnov <onlyjob@debian.org>:
Bug#828683; Package src:mc. (Thu, 06 Oct 2022 19:57:03 GMT) (full text, mbox, link).


Acknowledgement sent to Vagrant Cascadian <vagrant@reproducible-builds.org>:
Extra info received and forwarded to list. Copy sent to Dmitry Smirnov <onlyjob@debian.org>. (Thu, 06 Oct 2022 19:57:03 GMT) (full text, mbox, link).


Message #45 received at 828683@bugs.debian.org (full text, mbox, reply):

From: Vagrant Cascadian <vagrant@reproducible-builds.org>
To: "Yury V. Zaytsev" <yury@shurup.com>, Reiner Herrmann <reiner@reiner-h.de>
Cc: reproducible-builds@lists.alioth.debian.org, 828683@bugs.debian.org
Subject: Re: Bug#828683: mc: please make the build reproducible
Date: Thu, 06 Oct 2022 12:53:52 -0700
[Message part 1 (text/plain, inline)]
On 2016-06-27, Yury V. Zaytsev wrote:
> On Mon, 27 Jun 2016, Reiner Herrmann wrote:

Going through some old outstanding reproducible builds related bugs...

>> You are right, the mtime of the file is used for the manpage timestamp. 
>> But there is still a patch modifying the manpage: 
>> mcedit_full_path.patch. When this patch is upstreamed, the 
>> SOURCE_DATE_EPOCH patch is not needed, though it would still help when 
>> the manpages are patched.
>
> Thank you for the confirmation that my guesses are correct!
>
> However, I'm hesitant to apply SOURCE_DATE_EPOCH to anything that looks 
> like a nail. I believe that patching of upstream sources by Debian is such 
> an oft occurring situation, that I would rather look for at solution at 
> the packaging level. After all, builds from *upstream* sources are 
> *already* reproducible, in this case, it's the Debian build procedure that 
> is injecting randomness here.

I am biased, but I do think using SOURCE_DATE_EPOCH could still be a
reasonable approach upstream. There are some examples of how to use this
in various languages:

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

I did notice some things in the upstream code
doc/man/date-of-man-include.am:

MAN_DATE_CMD = \
        LC_ALL=$(DATE_LANG) @PERL@ -CS -MPOSIX -e '\
            @fi=lstat("'$${MAN_FILE}'"); \
            print POSIX::strftime("$(DATE_FORMAT)", localtime($$fi[9]));' 2>/dev/null

This uses localtime, which could be affected by timezone differences. To
my surprise, it doesn't appear to affect the results, as only the
patched manpage is affected:

  https://tests.reproducible-builds.org/debian/rb-pkg/bookworm/amd64/diffoscope-results/mc.html

Setting LC_ALL explicitly avoids variations due to the build
environment's locale(yay!), although the specified locales are not
guaranteed to be available (adding locales-all to build-depends could
fix that).

Again, surprisingly, this has not appeared to affect the results for the
locales tested on tests.reproducible-builds.org, though that may mean
the default locale is used even for the translated pages...


> For instance, it seems to me that it is only logical to set the mtime of 
> patched files to the mtime of the last patch that touched them, and this 
> will make the source mtime dependent builds fully reproducible.

The attached alternate implements this for mc by touching the potential
files before running configure with a consistent timestamp.

According to my local tests, applying this patch should make mc build
reproducibly once it lands in testing/bookworm! There are outstanding
build path issues tested in unstable and experimental.

It doesn't address the larger issue of files modified by debian/patches
having the current timestamp, which is a much more complicated
intersection of issues.


live well,
  vagrant
[0005-debian-rules-Ensure-consistent-timestamp-on-manpages.patch (text/x-diff, inline)]
From 4e69587954d29ec6bfc7d85b4b618724b16b840e Mon Sep 17 00:00:00 2001
From: Vagrant Cascadian <vagrant@reproducible-builds.org>
Date: Thu, 6 Oct 2022 19:25:11 +0000
Subject: [PATCH 5/5] debian/rules: Ensure consistent timestamp on manpages.

The upstream build system uses the file modification time of the .in
file for the manpage to embed into the generatated manpage, but if
debian/patches modify the .in files, the timestamp is updated,
resulting in builds performed in different months or years embedding a
different date.
---
 debian/rules | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/debian/rules b/debian/rules
index c633a73..bf8eb5e 100755
--- a/debian/rules
+++ b/debian/rules
@@ -25,6 +25,8 @@ override_dh_autoreconf:
 # AWK="awk" is inheritance of 4.7.* series, see http://bugs.debian.org/499723
 # might be still necessary for extfs scripts
 override_dh_auto_configure:
+	# Ensure reproducible timestamp on manpages
+	touch -d@$(SOURCE_DATE_EPOCH) doc/man/*.1.in doc/man/*/*.1.in
 	dh_auto_configure -- AWK="awk" X11_WWW="x-www-browser" \
 		--libexecdir='/usr/lib' \
 		--with-x \
-- 
2.37.2

[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Dmitry Smirnov <onlyjob@debian.org>:
Bug#828683; Package src:mc. (Thu, 22 Dec 2022 22:09:07 GMT) (full text, mbox, link).


Acknowledgement sent to Vagrant Cascadian <vagrant@reproducible-builds.org>:
Extra info received and forwarded to list. Copy sent to Dmitry Smirnov <onlyjob@debian.org>. (Thu, 22 Dec 2022 22:09:07 GMT) (full text, mbox, link).


Message #50 received at 828683@bugs.debian.org (full text, mbox, reply):

From: Vagrant Cascadian <vagrant@reproducible-builds.org>
To: "Yury V. Zaytsev" <yury@shurup.com>, Reiner Herrmann <reiner@reiner-h.de>
Cc: reproducible-builds@lists.alioth.debian.org, 828683@bugs.debian.org
Subject: Re: Bug#828683: mc: please make the build reproducible
Date: Thu, 22 Dec 2022 14:05:45 -0800
[Message part 1 (text/plain, inline)]
On 2022-10-06, Vagrant Cascadian wrote:
> The attached alternate implements this for mc by touching the potential
> files before running configure with a consistent timestamp.
>
> According to my local tests, applying this patch should make mc build
> reproducibly once it lands in testing/bookworm! There are outstanding
> build path issues tested in unstable and experimental.
...
> From 4e69587954d29ec6bfc7d85b4b618724b16b840e Mon Sep 17 00:00:00 2001
> From: Vagrant Cascadian <vagrant@reproducible-builds.org>
> Date: Thu, 6 Oct 2022 19:25:11 +0000
> Subject: [PATCH 5/5] debian/rules: Ensure consistent timestamp on manpages.
>
> The upstream build system uses the file modification time of the .in
> file for the manpage to embed into the generatated manpage, but if
> debian/patches modify the .in files, the timestamp is updated,
> resulting in builds performed in different months or years embedding a
> different date.
> ---
>  debian/rules | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/debian/rules b/debian/rules
> index c633a73..bf8eb5e 100755
> --- a/debian/rules
> +++ b/debian/rules
> @@ -25,6 +25,8 @@ override_dh_autoreconf:
>  # AWK="awk" is inheritance of 4.7.* series, see http://bugs.debian.org/499723
>  # might be still necessary for extfs scripts
>  override_dh_auto_configure:
> +	# Ensure reproducible timestamp on manpages
> +	touch -d@$(SOURCE_DATE_EPOCH) doc/man/*.1.in doc/man/*/*.1.in
>  	dh_auto_configure -- AWK="awk" X11_WWW="x-www-browser" \
>  		--libexecdir='/usr/lib' \
>  		--with-x \
> -- 
> 2.37.2

I Intend to NMU with this patch on the 29th (with a 10-day delay) unless
I hear otherwise.


live well,
  vagrant
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Dmitry Smirnov <onlyjob@debian.org>:
Bug#828683; Package src:mc. (Fri, 23 Dec 2022 10:15:04 GMT) (full text, mbox, link).


Acknowledgement sent to "Yury V. Zaytsev" <yury@shurup.com>:
Extra info received and forwarded to list. Copy sent to Dmitry Smirnov <onlyjob@debian.org>. (Fri, 23 Dec 2022 10:15:04 GMT) (full text, mbox, link).


Message #55 received at 828683@bugs.debian.org (full text, mbox, reply):

From: "Yury V. Zaytsev" <yury@shurup.com>
To: Vagrant Cascadian <vagrant@reproducible-builds.org>
Cc: Reiner Herrmann <reiner@reiner-h.de>, reproducible-builds@lists.alioth.debian.org, 828683@bugs.debian.org
Subject: Re: Bug#828683: mc: please make the build reproducible
Date: Fri, 23 Dec 2022 10:42:19 +0100 (CET)
On Thu, 22 Dec 2022, Vagrant Cascadian wrote:

> I Intend to NMU with this patch on the 29th (with a 10-day delay) unless 
> I hear otherwise.

I have no objections to that; please proceed, if you believe that this is 
the right thing to do. Your graceful heads up is appreciated.

I was just trying to explain, that in my opinion the source of the problem 
is resetting the timestamps while applying distro patches, so maybe it's 
worth looking at fixing the source instead of downstream consequences, and 
I'm unwilling to do something upstream to accomodate a distro issue, but 
at distro level, you decide what is the best way to go on.

-- 
Sincerely yours,
Yury V. Zaytsev



Information forwarded to debian-bugs-dist@lists.debian.org, Dmitry Smirnov <onlyjob@debian.org>:
Bug#828683; Package src:mc. (Tue, 10 Jan 2023 18:27:05 GMT) (full text, mbox, link).


Acknowledgement sent to Vagrant Cascadian <vagrant@reproducible-builds.org>:
Extra info received and forwarded to list. Copy sent to Dmitry Smirnov <onlyjob@debian.org>. (Tue, 10 Jan 2023 18:27:05 GMT) (full text, mbox, link).


Message #60 received at 828683@bugs.debian.org (full text, mbox, reply):

From: Vagrant Cascadian <vagrant@reproducible-builds.org>
To: "Yury V. Zaytsev" <yury@shurup.com>, Reiner Herrmann <reiner@reiner-h.de>
Cc: reproducible-builds@lists.alioth.debian.org, 828683@bugs.debian.org
Subject: Re: Bug#828683: mc: please make the build reproducible
Date: Tue, 10 Jan 2023 10:25:17 -0800
[Message part 1 (text/plain, inline)]
On 2022-12-22, Vagrant Cascadian wrote:
> On 2022-10-06, Vagrant Cascadian wrote:
>> The attached alternate implements this for mc by touching the potential
>> files before running configure with a consistent timestamp.
>>
>> According to my local tests, applying this patch should make mc build
>> reproducibly once it lands in testing/bookworm! There are outstanding
>> build path issues tested in unstable and experimental.
> ...
>> From 4e69587954d29ec6bfc7d85b4b618724b16b840e Mon Sep 17 00:00:00 2001
>> From: Vagrant Cascadian <vagrant@reproducible-builds.org>
>> Date: Thu, 6 Oct 2022 19:25:11 +0000
>> Subject: [PATCH 5/5] debian/rules: Ensure consistent timestamp on manpages.
>>
>> The upstream build system uses the file modification time of the .in
>> file for the manpage to embed into the generatated manpage, but if
>> debian/patches modify the .in files, the timestamp is updated,
>> resulting in builds performed in different months or years embedding a
>> different date.
>> ---
>>  debian/rules | 2 ++
>>  1 file changed, 2 insertions(+)
>>
>> diff --git a/debian/rules b/debian/rules
>> index c633a73..bf8eb5e 100755
>> --- a/debian/rules
>> +++ b/debian/rules
>> @@ -25,6 +25,8 @@ override_dh_autoreconf:
>>  # AWK="awk" is inheritance of 4.7.* series, see http://bugs.debian.org/499723
>>  # might be still necessary for extfs scripts
>>  override_dh_auto_configure:
>> +	# Ensure reproducible timestamp on manpages
>> +	touch -d@$(SOURCE_DATE_EPOCH) doc/man/*.1.in doc/man/*/*.1.in
>>  	dh_auto_configure -- AWK="awk" X11_WWW="x-www-browser" \
>>  		--libexecdir='/usr/lib' \
>>  		--with-x \
>> -- 
>> 2.37.2
>
> I Intend to NMU with this patch on the 29th (with a 10-day delay) unless
> I hear otherwise.

A little behind schedule, and a little more conservative patch (only
touching the currently patched mcedit manpage)...

Uploaded NMU to DELAYED/10:

diff -Nru mc-4.8.28/debian/changelog mc-4.8.28/debian/changelog
--- mc-4.8.28/debian/changelog	2022-04-02 15:10:15.000000000 -0700
+++ mc-4.8.28/debian/changelog	2023-01-10 09:50:36.000000000 -0800
@@ -1,3 +1,11 @@
+mc (3:4.8.28-1.1) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * debian/rules: Ensure consistent timestamp on mcedit manpage.
+    (Closes: #828683)
+
+ -- Vagrant Cascadian <vagrant@reproducible-builds.org>  Tue, 10 Jan 2023 09:50:36 -0800
+
 mc (3:4.8.28-1) unstable; urgency=medium
 
   * New upstream release.
diff -Nru mc-4.8.28/debian/rules mc-4.8.28/debian/rules
--- mc-4.8.28/debian/rules	2018-06-05 21:11:33.000000000 -0700
+++ mc-4.8.28/debian/rules	2023-01-10 09:49:58.000000000 -0800
@@ -25,6 +25,9 @@
 # AWK="awk" is inheritance of 4.7.* series, see http://bugs.debian.org/499723
 # might be still necessary for extfs scripts
 override_dh_auto_configure:
+	# Ensure reproducible timestamp on mcedit manpage, which is
+	# patched from debian/patches
+	touch -d@$(SOURCE_DATE_EPOCH) doc/man/mcedit.1.in
 	dh_auto_configure -- AWK="awk" X11_WWW="x-www-browser" \
 		--libexecdir='/usr/lib' \
 		--with-x \
[signature.asc (application/pgp-signature, inline)]

Information stored :
Bug#828683; Package src:mc. (Tue, 10 Jan 2023 18:36:05 GMT) (full text, mbox, link).


Acknowledgement sent to Vagrant Cascadian <vagrant@reproducible-builds.org>:
Extra info received and filed, but not forwarded. (Tue, 10 Jan 2023 18:36:05 GMT) (full text, mbox, link).


Message #65 received at 828683-quiet@bugs.debian.org (full text, mbox, reply):

From: Vagrant Cascadian <vagrant@reproducible-builds.org>
To: 828683-quiet@bugs.debian.org
Subject: Re: Bug#828683: mc: please make the build reproducible
Date: Tue, 10 Jan 2023 10:34:11 -0800
[Message part 1 (text/plain, inline)]
Control: tags 828683 pending

On 2023-01-10, Vagrant Cascadian wrote:
> Uploaded NMU to DELAYED/10:
>
> diff -Nru mc-4.8.28/debian/changelog mc-4.8.28/debian/changelog
> --- mc-4.8.28/debian/changelog	2022-04-02 15:10:15.000000000 -0700
> +++ mc-4.8.28/debian/changelog	2023-01-10 09:50:36.000000000 -0800
> @@ -1,3 +1,11 @@
> +mc (3:4.8.28-1.1) unstable; urgency=medium
> +
> +  * Non-maintainer upload.
> +  * debian/rules: Ensure consistent timestamp on mcedit manpage.
> +    (Closes: #828683)
> +
> + -- Vagrant Cascadian <vagrant@reproducible-builds.org>  Tue, 10 Jan 2023 09:50:36 -0800
> +
>  mc (3:4.8.28-1) unstable; urgency=medium
>  
>    * New upstream release.
> diff -Nru mc-4.8.28/debian/rules mc-4.8.28/debian/rules
> --- mc-4.8.28/debian/rules	2018-06-05 21:11:33.000000000 -0700
> +++ mc-4.8.28/debian/rules	2023-01-10 09:49:58.000000000 -0800
> @@ -25,6 +25,9 @@
>  # AWK="awk" is inheritance of 4.7.* series, see http://bugs.debian.org/499723
>  # might be still necessary for extfs scripts
>  override_dh_auto_configure:
> +	# Ensure reproducible timestamp on mcedit manpage, which is
> +	# patched from debian/patches
> +	touch -d@$(SOURCE_DATE_EPOCH) doc/man/mcedit.1.in
>  	dh_auto_configure -- AWK="awk" X11_WWW="x-www-browser" \
>  		--libexecdir='/usr/lib' \
>  		--with-x \
[signature.asc (application/pgp-signature, inline)]

Added tag(s) pending. Request was from Vagrant Cascadian <vagrant@reproducible-builds.org> to 828683-quiet@bugs.debian.org. (Tue, 10 Jan 2023 18:36:05 GMT) (full text, mbox, link).


Message sent on to Reiner Herrmann <reiner@reiner-h.de>:
Bug#828683. (Tue, 10 Jan 2023 18:36:07 GMT) (full text, mbox, link).


Message #70 received at 828683-submitter@bugs.debian.org (full text, mbox, reply):

From: Vagrant Cascadian <noreply@salsa.debian.org>
To: 828683-submitter@bugs.debian.org
Subject: Bug#828683 marked as pending in mc
Date: Tue, 10 Jan 2023 18:33:12 +0000
Control: tag -1 pending

Hello,

Bug #828683 in mc reported by you has been fixed in the
Git repository and is awaiting an upload. You can see the commit
message below and you can check the diff of the fix at:

https://salsa.debian.org/debian/mc/-/commit/f70318e0579521c14029cc31f3c7c391c069b9d9

------------------------------------------------------------------------
debian/rules: Ensure consistent timestamp on mcedit manpage.
(Closes: #828683)

The upstream build system uses the file modification time of the .in
file for the manpage to embed into the generatated manpage, but if
debian/patches modify the .in files, the timestamp is updated,
resulting in builds performed in different months or years embedding a
different date.
------------------------------------------------------------------------

(this message was generated automatically)
-- 
Greetings

https://bugs.debian.org/828683



Reply sent to Vagrant Cascadian <vagrant@reproducible-builds.org>:
You have taken responsibility. (Fri, 20 Jan 2023 19:09:09 GMT) (full text, mbox, link).


Notification sent to Reiner Herrmann <reiner@reiner-h.de>:
Bug acknowledged by developer. (Fri, 20 Jan 2023 19:09:09 GMT) (full text, mbox, link).


Message #75 received at 828683-close@bugs.debian.org (full text, mbox, reply):

From: Debian FTP Masters <ftpmaster@ftp-master.debian.org>
To: 828683-close@bugs.debian.org
Subject: Bug#828683: fixed in mc 3:4.8.28-1.1
Date: Fri, 20 Jan 2023 19:06:34 +0000
Source: mc
Source-Version: 3:4.8.28-1.1
Done: Vagrant Cascadian <vagrant@reproducible-builds.org>

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

Debian distribution maintenance software
pp.
Vagrant Cascadian <vagrant@reproducible-builds.org> (supplier of updated mc 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 ftpmaster@ftp-master.debian.org)


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

Format: 1.8
Date: Tue, 10 Jan 2023 09:50:36 -0800
Source: mc
Architecture: source
Version: 3:4.8.28-1.1
Distribution: unstable
Urgency: medium
Maintainer: Dmitry Smirnov <onlyjob@debian.org>
Changed-By: Vagrant Cascadian <vagrant@reproducible-builds.org>
Closes: 828683
Changes:
 mc (3:4.8.28-1.1) unstable; urgency=medium
 .
   * Non-maintainer upload.
   * debian/rules: Ensure consistent timestamp on mcedit manpage.
     (Closes: #828683)
Checksums-Sha1:
 40c3b93d2b67da8af3cc9485ff897bc31c5fabd0 1551 mc_4.8.28-1.1.dsc
 7ca0936f1e5f4ccffc9683bd4f055d3bab0abf10 48000 mc_4.8.28-1.1.debian.tar.xz
 8d788125c72b38b2019fda1555d616f930c5559e 8747 mc_4.8.28-1.1_arm64.buildinfo
Checksums-Sha256:
 a66451fd665e3bde997005b406fd1d9e63d5cda2d590b68f327313c5d4c5c76d 1551 mc_4.8.28-1.1.dsc
 4a864536e33c6a7f027901faef59f643be7894893b474b63f4cc1e26e1740916 48000 mc_4.8.28-1.1.debian.tar.xz
 a674b55eb3ac956a9da657c8c56b313f417f683e5814c8211e1e190f0b825824 8747 mc_4.8.28-1.1_arm64.buildinfo
Files:
 48d53869e66779e53d8ddf64fce66fd2 1551 utils optional mc_4.8.28-1.1.dsc
 3936f52b4b23a338aa4ee684b32296b3 48000 utils optional mc_4.8.28-1.1.debian.tar.xz
 fff9c258de09ac351036933da28367a5 8747 utils optional mc_4.8.28-1.1_arm64.buildinfo

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

iJYEARYKAD4WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCY72siyAcdmFncmFudEBy
ZXByb2R1Y2libGUtYnVpbGRzLm9yZwAKCRDcUY/If5cWqtBhAP4v/J54YXrY11y4
Kztt/O87um47ad+Ec8lLw4JK9PbcEgEA4hb1Ky4t+t3ysIWvpQvIhAiSNYEIh0sP
79MsvsiKRwc=
=fAys
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Fri, 24 Mar 2023 07:27:04 GMT) (full text, mbox, link).


Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Wed May 17 10:58:58 2023; Machine Name: bembo

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.