Bug#981245: dh_strip: Avoid conflicting dbg/dbgsym files

2022-12-20 Thread Jakub Wilk

* Matthias Klose , 2021-01-28 11:42:

Example usage:
https://github.com/rpm-software-management/rpm/blob/master/scripts/find-debuginfo.sh


The link has become 404 in the mean time.

I think this was (mostly?) the same script as /usr/bin/find-debuginfo 
from debugedit.


--
Jakub Wilk



Bug#981245: dh_strip: Avoid conflicting dbg/dbgsym files

2021-01-28 Thread Matthias Klose
Package: debhelper
Version: 13.3.1
Severity: important

As seen with the openjdk-N packages, the -dbg binary packages contain
conflicting files, caused by some identical object files.  The work-around used
there is to add package conflicts.

dh_strip creating dbgsym packages doesn't offer any possibility to add package
conflicts directly, and afaik piuparts isn't checking for file conflicts in
dbgsym packages.

The solution used in the rpm world is to avoid these file conflicts by
generating a unique build-id using the debugedit command.  debugedit 4.16.x
started to support the --build-id-seed option.

  debugedit --build-id \
--build-id-seed='-' \


The seed should be at least the binary package name, probably also together with
the package version.

Example usage:
https://github.com/rpm-software-management/rpm/blob/master/scripts/find-debuginfo.sh