Github messages for voidlinux
 help / color / mirror / Atom feed
From: ericonr <ericonr@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: RFC: Check for reproducible builds.
Date: Sat, 01 May 2021 03:01:40 +0200	[thread overview]
Message-ID: <20210501010140.XI7_QeH5iBkiJV_cnxniISKhJ2odTmynwfwGSIaGovg@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-30588@inbox.vuxu.org>

[-- Attachment #1: Type: text/plain, Size: 2889 bytes --]

New comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/30588#issuecomment-830478097

Comment:
> We shouldn't improve deterministic builds because we don't have deterministic builds. I don't see how that's a valid reason.

The point is that the checksum won't match in 100% of the cases because of the metadata (specifically `source-revisions` - when you update the template with the new checksum for the package, that will change the commit hash and therefore the checksum; it's a loop). Most (all?) reproducible builds projects start from a binary artifact produced by the build and check if they can re-generate that based on information they had about the build environment, instead of checking if the builder produced the expected binary. I believe guix tries to check checksums from the bootstrap build process, but they always start from 0, which is a very different situation than what we have.

The determinism I was talking about wasn't in the sense of reproducible-builds, but in the sense that we can't control the value of `source-revisions` until the package has been built.

> There are problems with changing metadata, but there are ways around this. We have all the moving parts available and can work on them.

Which is why I'm proposing to study them. A content checksum (like our `@hash` checksum for templates) that skips `props.plist` would do most of the work (though it'd be slower). The issue then would be how to enforce policy to make people build packages for all archs, with the same settings used by builders (and then you have to take into account that `SOURCE_DATE_EPOCH` is derived from when a template was last touched, and that's also a loop of information, because a commit with a different date will once again alter the date, and this value *can* appear in normal files, for things like "build time"; this should be a rare case, though).

I don't think we have resources for a package archive or a "rebuilder" server that just tries to rebuild packages on its own, but I don't think the added workload and noise ("is this checksum wrong because someone forgot to udpate it or because something changed?") makes it worth having reproducible builds tracked in this repository. I would gladly contribute to a separate repository that tracks "verifications" from void users, and we could figure out some way to calculate "hashes" that skip the difference caused by building from different commits (which would, unfortunately, partly defeat the purpose of reproducible-builds: to be able to verify that packages are exactly the same by simply comparing hashes from raw archives, without complicated tools).

To be clear, I am very interested in this work, and would like to see Void more reproducible (and have its reproducibility quantified as well). But I don't think this is a correct direction.

  parent reply	other threads:[~2021-05-01  1:01 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-30  8:18 [PR PATCH] " Gottox
2021-04-30 12:53 ` [PR REVIEW] " ericonr
2021-04-30 13:01 ` ericonr
2021-04-30 15:55 ` ericonr
2021-04-30 16:59 ` Chocimier
2021-04-30 17:18 ` ericonr
2021-04-30 17:45 ` ericonr
2021-04-30 23:56 ` Gottox
2021-05-01  0:00 ` Gottox
2021-05-01  0:57 ` ericonr
2021-05-01  1:01 ` ericonr [this message]
2021-05-21 13:49 ` [PR PATCH] [Closed]: " Gottox

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210501010140.XI7_QeH5iBkiJV_cnxniISKhJ2odTmynwfwGSIaGovg@z \
    --to=ericonr@users.noreply.github.com \
    --cc=ml@inbox.vuxu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).