Source: xscreensaver Version: 5.34-1 Severity: wishlist Tags: patch User: reproducible-bui...@lists.alioth.debian.org Usertags: fileordering
Dear Maintainer, While working on the "reproducible builds" effort [1], we have noticed that xscreensaver could not be built reproducibly. The file hacks/Makefile.in uses wildcards to obtain parameters for a script, leading to unstable input file order and potentially different resulting binaries. I have attached a patch to use a fixed, sorted order for these files. This makes the build reproducible for me in my local test environment. Regards, Sascha [1]: https://wiki.debian.org/ReproducibleBuilds
diff --git a/debian/patches/81_deterministic_file_order.patch b/debian/patches/81_deterministic_file_order.patch new file mode 100644 index 0000000..3383986 --- /dev/null +++ b/debian/patches/81_deterministic_file_order.patch @@ -0,0 +1,13 @@ +--- a/hacks/Makefile.in ++++ b/hacks/Makefile.in +@@ -854,8 +854,8 @@ + + m6502.h: + @echo "building m6502.h from $(srcdir)/images/m6502/*.asm"; \ +- UTILS_SRC="$(UTILS_SRC)" \ +- $(srcdir)/m6502.sh m6502.h $(srcdir)/images/m6502/*.asm ++ find $(srcdir)/images/m6502/ -name '*.asm' | LC_ALL=C sort | \ ++ UTILS_SRC="$(UTILS_SRC)" xargs $(srcdir)/m6502.sh m6502.h + + m6502.o: m6502.h + m6502: m6502.o asm6502.o $(HACK_OBJS) $(ATV) diff --git a/debian/patches/series b/debian/patches/series index e446a27..7c98703 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -21,3 +21,4 @@ 57_grabDesktopImages_default_off.patch 80_Makefile_in-clean-fix.patch +81_deterministic_file_order.patch