[pacman-dev] [PATCH 3/4] makepkg: unify source file times for improved build reproducibility

Eli Schwartz eschwartz93 at gmail.com
Fri Apr 21 02:39:26 UTC 2017


On 04/17/2017 08:03 AM, Allan McRae wrote:
> From: Levente Polyak <anthraxx at archlinux.org>
[...]>  run_build() {
> +	# unify source times before building for reproducibility
> +	find "$srcdir" -exec touch -h -d "@${SOURCE_DATE_EPOCH}" {} \;
> +
>  	run_function_safe "build"
>  }

Just a general question on "why do we want this" (and the followup patch
to do this at the beginning of the package() step)...

It is one thing for makepkg to fiddle with its own internal logic to
respect SOURCE_DATE_EPOCH with regard to package metadata, installed
file modification times, etc. but as mentioned in the other thread, it
is not makepkg's job to ensure that, for example, python's compiled
bytecode respects SOURCE_DATE_EPOCH. Any build/generation process that
changes its own output based on the reported date of the source files,
is doing something wrong anyway.

Moreover, this breaks incremental builds by making the build system
think all files have been modified and must be recompiled.
Incremental builds are currently a perfectly valid use case for e.g.
*-git or other devel packages (assuming one is building for their own
computer, isn't worried about automagic/non-clean-chroot dependencies,
and is reasonably confident that the build system in question doesn't
fall on its face when asked to do incremental builds).

I very much do not want this to be accepted. :)

-- 
Eli Schwartz

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://lists.archlinux.org/pipermail/pacman-dev/attachments/20170420/6675e525/attachment.asc>


More information about the pacman-dev mailing list