Source: xtb Severity: normal Tags: patch User: reproducible-bui...@lists.alioth.debian.org Usertags: hostname timestamps username X-Debbugs-Cc: reproducible-b...@lists.alioth.debian.org
The time, username and hostname are embedded in /usr/bin/xtb and various other files: https://tests.reproducible-builds.org/debian/rb-pkg/bookworm/amd64/diffoscope-results/xtb.html /usr/bin/xtb 2022-11-12 vs. 2023-12-15 'pbuilder1@ionos5-amd64' vs. 'pbuilder2@i-capture-the-hostname' The attached patch fixes this by patching meson.build to use SOURCE_DATE_EPOCH for the date, and set placeholder values for the user and hostname. According to my local tests, With this patch applied xtb should build reproducibly on tests.reproducible-builds.org! Thanks for maintaining xtb! live well, vagrant
From 19839bbb88cb080ed6644cba7fd8b9ed01537c6a Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian <vagr...@reproducible-builds.org> Date: Thu, 17 Nov 2022 03:43:17 +0000 Subject: [PATCH] meson.build: Fix reproducible builds by using SOURCE_DATE_EPOCH to set timestamp and set 'author' and 'hostname' to fixed values. https://reproducible-builds.org/docs/source-date-epoch/ --- meson.build | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/meson.build b/meson.build index d6e6432..5caeb21 100644 --- a/meson.build +++ b/meson.build @@ -57,9 +57,9 @@ config = configuration_data({ 'description': 'Semiempirical Extended Tight-Binding Program Package', 'version': meson.project_version(), 'commit': commit, - 'date': run_command(python, '-c', 'import datetime; print(datetime.date.today().strftime("%Y-%m-%d"))').stdout().strip(), - 'author': run_command(python, '-c', 'import getpass; print(getpass.getuser())').stdout().strip(), - 'origin': run_command(python, '-c', 'import socket; print(socket.gethostname())').stdout().strip(), + 'date': run_command(python, '-c', 'import os; import time; import datetime; print(datetime.datetime.utcfromtimestamp(int(os.environ.get("SOURCE_DATE_EPOCH", time.time()))).strftime("%Y-%m-%d"))').stdout().strip(), + 'author': 'builduser', + 'origin': 'buildhost', 'prefix': get_option('prefix'), 'mandir': get_option('mandir'), 'bindir': get_option('bindir'), -- 2.30.2
signature.asc
Description: PGP signature