Patrick Williams | 92b42cb | 2022-09-03 06:53:57 -0500 | [diff] [blame^] | 1 | From e49e86bd3199f51ada8a4a1d51aa8d627645279e Mon Sep 17 00:00:00 2001 |
| 2 | From: Richard Purdie <richard.purdie@linuxfoundation.org> |
| 3 | Date: Sat, 27 Feb 2021 23:42:03 +0000 |
| 4 | Subject: [PATCH] Fix reproducibility issues |
| 5 | |
| 6 | In order to build deterministic binaries, we need to sort the wildcard expansion |
| 7 | so the libraries are linked in the same order each time. This fixes reproducibility |
| 8 | issues within syslinux builds. |
| 9 | |
| 10 | Upstream-Status: Inactive-Upstream |
| 11 | RP 2021/3/1 |
| 12 | |
| 13 | Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> |
| 14 | --- |
| 15 | mk/lib.mk | 4 ++-- |
| 16 | 1 file changed, 2 insertions(+), 2 deletions(-) |
| 17 | |
| 18 | diff --git a/mk/lib.mk b/mk/lib.mk |
| 19 | index f3fb07c..815698c 100644 |
| 20 | --- a/mk/lib.mk |
| 21 | +++ b/mk/lib.mk |
| 22 | @@ -130,8 +130,8 @@ LIBENTRY_OBJS = \ |
| 23 | exit.o |
| 24 | |
| 25 | LIBGCC_OBJS = \ |
| 26 | - $(patsubst $(com32)/lib/%.c,%.o,$(wildcard $(com32)/lib/$(ARCH)/libgcc/*.c)) \ |
| 27 | - $(patsubst $(com32)/lib/%.S,%.o,$(wildcard $(com32)/lib/$(ARCH)/libgcc/*.S)) |
| 28 | + $(sort $(patsubst $(com32)/lib/%.c,%.o,$(wildcard $(com32)/lib/$(ARCH)/libgcc/*.c))) \ |
| 29 | + $(sort $(patsubst $(com32)/lib/%.S,%.o,$(wildcard $(com32)/lib/$(ARCH)/libgcc/*.S))) |
| 30 | |
| 31 | LIBCONSOLE_OBJS = \ |
| 32 | \ |