[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1011428: cdbackup: reproducible-builds: embedded build paths in various binaries



Source: cdbackup
Severity: normal
Tags: patch
User: reproducible-builds@lists.alioth.debian.org
Usertags: buildpath
X-Debbugs-Cc: reproducible-bugs@lists.alioth.debian.org

The build path is embedded in /usr/bin/cdbackup and /usr/bin/cdrestore:

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

  /build/1st/cdbackup-0.7.1/cdbackup.c:421
  vs.
  /build/2/cdbackup-0.7.1/2nd/cdbackup.c:421

The attached patch fixes this by explicitly passing CFLAGS to
dh_auto_build in debian/rules, which includes the -ffile-prefix-map
argument to avoid embedding the absolute path in compiled files.


With this patch applied, cdbackup should build reproducibly on
tests.reproducible-builds.org!


live well,
  vagrant
From 5cc4d882ffe7bd447c315e43ced64bbee1b9a4ac Mon Sep 17 00:00:00 2001
From: Vagrant Cascadian <vagrant@reproducible-builds.org>
Date: Sun, 22 May 2022 17:40:35 +0000
Subject: [PATCH] debian/rules: Explicitly pass CFLAGS to dh_auto_build.

---
 debian/rules | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/debian/rules b/debian/rules
index 123ed55..4618c51 100755
--- a/debian/rules
+++ b/debian/rules
@@ -6,6 +6,9 @@
 %:
 	dh  $@
 
+override_dh_auto_build:
+	dh_auto_build -- CFLAGS="$(CFLAGS)"
+
 # Use override_dh_* targets to customize this.
 # ---------------------------------------------------
 # Followings are the old debian/rules
-- 
2.36.1

Attachment: signature.asc
Description: PGP signature


Reply to: