Source: debhelper
Version: 13.2
Severity: wishlist
Tags: patch
User: reproducible-bui...@lists.alioth.debian.org
Usertags: filesystem toolchain
X-Debbugs-Cc: reproducible-b...@lists.alioth.debian.org
Hi,
Whilst working on the Reproducible Builds effort [0] I noticed that
dh_missing was choosing example files in a non-deterministic manner:
As an example, perhaps you want to replace:
- * muroarstream.1
+ * muroar_write.3
with:
- * usr/share/man/man1/muroarstream.1
+ * usr/share/man/man3/muroar_write.3
in a file in debian/ or as argument to one of the dh_* tools called
from debian/rules.
To be clear, this does not affect the reproducibility of packages that
use dh_missing, but it does introduce unnecessary noise between two
build logs. (I use these often when diagnosing reproducibility
issues.)
Patch attached. An alternative might be to use the preprocess part of
File::Find, but just throwing a sort in here is a bit shorter.
[0] https://reproducible-builds.org/
Regards,
--
,''`.
: :' : Chris Lamb
`. `'` la...@debian.org / chris-lamb.co.uk
`-
diff --git a/dh_missing b/dh_missing
index f5e7c78..af30543 100755
--- a/dh_missing
+++ b/dh_missing
@@ -198,7 +198,7 @@ if (@missing) {
my %seen_basename = map { basename($_) => $_ } @installed;
my $multiarch = dpkg_architecture_value("DEB_HOST_MULTIARCH");
my $seen_ma_value = 0;
- for my $file (@missing) {
+ for my $file (sort @missing) {
my $basename = basename($file);
if (exists($seen_basename{$basename})) {
my $alt_source = $seen_basename{$basename};