Andrew Geissler | d159c7f | 2021-09-02 21:05:58 -0500 | [diff] [blame] | 1 | From 905333229103510e9dee2fec29b261ccedb031d0 Mon Sep 17 00:00:00 2001 |
| 2 | From: Alexander Kanavin <alex.kanavin@gmail.com> |
| 3 | Date: Fri, 20 Aug 2021 19:37:04 +0000 |
| 4 | Subject: [PATCH] Makefile: restore build reproducibility |
| 5 | |
| 6 | wildcards result in an unpredictable order, and thus different binary outputs |
| 7 | in otherwise identical builds. |
| 8 | |
| 9 | Upstream-Status: Submitted [https://github.com/smuellerDD/jitterentropy-library/pull/67] |
| 10 | Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> |
| 11 | --- |
| 12 | Makefile | 2 +- |
| 13 | 1 file changed, 1 insertion(+), 1 deletion(-) |
| 14 | |
| 15 | diff --git a/Makefile b/Makefile |
| 16 | index 42932d8..dfb96a8 100644 |
| 17 | --- a/Makefile |
| 18 | +++ b/Makefile |
| 19 | @@ -36,7 +36,7 @@ LIBMINOR=$(shell cat $(SRCDIR)/jitterentropy-base.c | grep define | grep MINVERS |
| 20 | LIBPATCH=$(shell cat $(SRCDIR)/jitterentropy-base.c | grep define | grep PATCHLEVEL | awk '{print $$3}') |
| 21 | LIBVERSION := $(LIBMAJOR).$(LIBMINOR).$(LIBPATCH) |
| 22 | |
| 23 | -C_SRCS := $(wildcard $(SRCDIR)/*.c) |
| 24 | +C_SRCS := $(sort $(wildcard $(SRCDIR)/*.c)) |
| 25 | C_OBJS := ${C_SRCS:.c=.o} |
| 26 | OBJS := $(C_OBJS) |
| 27 | |