Bug#985553: dpkg: RFC use gcc .spec files for fixfilepath/fixdebugpath

Vagrant Cascadian vagrant at reproducible-builds.org
Fri Mar 19 18:32:52 GMT 2021


Package: dpkg
Severity: normal
Tags: patch
User: reproducible-builds at lists.alioth.debian.org
Usertags: buildpath
X-Debbugs-Cc: reproducible-bugs at lists.alioth.debian.org

While the reproducible=+fixfilepath and reproducible=+fixdebugpath are
very helpful in stripping out the build path from binaries, many
binaries still end up including the build path because they also embed
the compiler flags (e.g. -ffile-prefix-map=/path/to/build-XYZ=.):

  https://tests.reproducible-builds.org/debian/issues/unstable/records_build_flags_issue.html

At the moment, we have identified over 150 packages in Debian affected
by this issue, though there are probably more that have not yet been
identified. Some packages may work around this issue by sanitizing or
stripping -ffile-prefix-map and -fdebug-prefix-map, but handling this on
a per-package basis is a bit of a whack-a-mole approach.


The attached patch attempts to switch fixfilepath and fixdebugpath to
use .spec files with the DEB_BUILD_PATH environment variable, which is
currently used internally for the fixfilepath and fixdebugpath
features.

Note that it is only a partial patch; it doesn't export DEB_BUILD_PATH
in dpkg-buildpackage and/or dpkg-buildflags; help as to the best place
to implement that would be appreciated!

Instead of changing fixfilepath/fixdebugpath, it might also be better to
add new options instead, as this is a significant change of the
implementation.


Interested to hear your thoughts everyone!


live well,
  vagrant

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Implement-reproducible-fixfilepath-fixdebugpath-as-s.patch
Type: text/x-diff
Size: 2230 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/reproducible-bugs/attachments/20210319/64eedf40/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 227 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/reproducible-bugs/attachments/20210319/64eedf40/attachment.sig>


More information about the Reproducible-bugs mailing list