Debian Bug report logs -
#1020668
jnettop: reproducible-builds: Embedded build path in /usr/sbin/jnettop
Reply or subscribe to this bug.
Toggle useless messages
Report forwarded
to debian-bugs-dist@lists.debian.org, reproducible-bugs@lists.alioth.debian.org, Ari Pollak <ari@debian.org>:
Bug#1020668; Package src:jnettop.
(Sun, 25 Sep 2022 00:39:04 GMT) (full text, mbox, link).
Acknowledgement sent
to Vagrant Cascadian <vagrant@reproducible-builds.org>:
New Bug report received and forwarded. Copy sent to reproducible-bugs@lists.alioth.debian.org, Ari Pollak <ari@debian.org>.
(Sun, 25 Sep 2022 00:39:04 GMT) (full text, mbox, link).
Message #5 received at submit@bugs.debian.org (full text, mbox, reply):
[Message part 1 (text/plain, inline)]
Source: jnettop
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/sbin/jnettop:
https://tests.reproducible-builds.org/debian/rb-pkg/unstable/amd64/diffoscope-results/jnettop.html
/build/1st/jnettop-0.52/game.c:49
vs.
/build/2/jnettop-0.52/2nd/game.c:49
The attached patches fix this in debian/rules by passing CFLAGS to make,
and adding the -ffile-prefix-map argument to CFLAGS.
With these patches applied jnettop should build reproducibly on
tests.reproducible-builds.org!
Thanks for maintaining jnettop!
live well,
vagrant
[0001-debian-rules-Pass-CFLAGS-to-make.patch (text/x-diff, inline)]
From 08ee9cd447f5e322c65ef14ff38c5b21c96d8915 Mon Sep 17 00:00:00 2001
From: Vagrant Cascadian <vagrant@reproducible-builds.org>
Date: Sun, 25 Sep 2022 00:31:06 +0000
Subject: [PATCH 1/2] debian/rules: Pass CFLAGS to make.
---
debian/rules | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/debian/rules b/debian/rules
index 2952d66..435303c 100755
--- a/debian/rules
+++ b/debian/rules
@@ -35,7 +35,7 @@ build-stamp: config.status
dh_testdir
# Add here commands to compile the package.
- $(MAKE)
+ $(MAKE) CFLAGS="$(CFLAGS)"
#/usr/bin/docbook-to-man debian/jnettop.sgml > jnettop.1
touch build-stamp
--
2.37.2
[0002-debian-rules-Add-ffile-prefix-map-to-CFLAGS-to-avoid.patch (text/x-diff, inline)]
From ef4bfd21187965d9e73c0f46d7a753b4c1603bbc Mon Sep 17 00:00:00 2001
From: Vagrant Cascadian <vagrant@reproducible-builds.org>
Date: Sun, 25 Sep 2022 00:31:32 +0000
Subject: [PATCH 2/2] debian/rules: Add -ffile-prefix-map to CFLAGS to avoid
embedding build paths.
https://reproducible-builds.org/docs/build-path/
---
debian/rules | 2 ++
1 file changed, 2 insertions(+)
diff --git a/debian/rules b/debian/rules
index 435303c..9a947d0 100755
--- a/debian/rules
+++ b/debian/rules
@@ -13,6 +13,8 @@ DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
CFLAGS = -Wall -g
+# Avoid embedding build path in binaries
+CFLAGS += -ffile-prefix-map=$(CURDIR)=.
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0
--
2.37.2
[signature.asc (application/pgp-signature, inline)]
Information forwarded
to debian-bugs-dist@lists.debian.org, Ari Pollak <ari@debian.org>:
Bug#1020668; Package src:jnettop.
(Sun, 25 Sep 2022 00:51: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 Ari Pollak <ari@debian.org>.
(Sun, 25 Sep 2022 00:51:05 GMT) (full text, mbox, link).
Message #10 received at 1020668@bugs.debian.org (full text, mbox, reply):
[Message part 1 (text/plain, inline)]
On 2022-09-24, Vagrant Cascadian wrote:
> The build path is embedded in /usr/sbin/jnettop:
>
> https://tests.reproducible-builds.org/debian/rb-pkg/unstable/amd64/diffoscope-results/jnettop.html
>
Er, the example difference was wrong, it's:
/build/1st/jnettop-0.13.0/jnettop.c:47
vs.
/build/2/jnettop-0.13.0/2nd/jnettop.c:47
Sorry if that caused any confusion.
live well,
vagrant
[signature.asc (application/pgp-signature, inline)]
Send a report that this bug log contains spam.
Debian bug tracking system administrator <owner@bugs.debian.org>.
Last modified:
Wed May 17 13:27:50 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.