From 7df82baf4680cb43354a457159e5f814be1fae4c Mon Sep 17 00:00:00 2001 From: Christoph Berg Date: Wed, 18 May 2016 10:42:20 +0200 Subject: [PATCH] Sort list of objects in src/backend/distributed/Makefile Make's $(wildcard) does not sort the glob result, but returns filenames in filesystem ordering. This makes the build result vary and hence unreproducible on the binary level. Fix by adding $(sort). Spotted by Debian's reproducible builds project. --- src/backend/distributed/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backend/distributed/Makefile b/src/backend/distributed/Makefile index 6a26d1cb0..13ae016ef 100644 --- a/src/backend/distributed/Makefile +++ b/src/backend/distributed/Makefile @@ -20,7 +20,7 @@ SUBDIRS = . commands executor master planner relay test utils worker # That patsubst rule searches all directories listed in SUBDIRS for .c # files, and adds the corresponding .o files to OBJS OBJS += \ - $(patsubst $(citus_abs_srcdir)/%.c,%.o,$(foreach dir,$(SUBDIRS), $(wildcard $(citus_abs_srcdir)/$(dir)/*.c))) + $(patsubst $(citus_abs_srcdir)/%.c,%.o,$(foreach dir,$(SUBDIRS), $(sort $(wildcard $(citus_abs_srcdir)/$(dir)/*.c)))) # be explicit about the default target all: