From 5b29a1d4b1d25a16c24c2365980ac5fd847e1aa6 Mon Sep 17 00:00:00 2001 From: "Bernhard M. Wiedemann" Date: Mon, 30 Jul 2018 19:02:46 +0200 Subject: [PATCH] find-debuginfo.sh: sort output of find to make build results more reproducible in spite of indeterministic filesystem readdir order. For openSUSE, this helped to make squid, openssh, postfix and shadow packages build reproducibly. See https://reproducible-builds.org/ for why this is good. --- scripts/find-debuginfo.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/find-debuginfo.sh b/scripts/find-debuginfo.sh index 44d164299e..11397b7e8f 100755 --- a/scripts/find-debuginfo.sh +++ b/scripts/find-debuginfo.sh @@ -487,7 +487,7 @@ fi # Invoke the DWARF Compressor utility. if $run_dwz \ && [ -d "${RPM_BUILD_ROOT}/usr/lib/debug" ]; then - readarray dwz_files < <(cd "${RPM_BUILD_ROOT}/usr/lib/debug"; find -type f -name \*.debug) + readarray dwz_files < <(cd "${RPM_BUILD_ROOT}/usr/lib/debug"; find -type f -name \*.debug | LC_ALL=C sort) if [ ${#dwz_files[@]} -gt 0 ]; then dwz_multifile_name="${RPM_PACKAGE_NAME}-${RPM_PACKAGE_VERSION}-${RPM_PACKAGE_RELEASE}.${RPM_ARCH}" dwz_multifile_suffix=