]> granicus.if.org Git - git/commitdiff
git-gui: sort entries in optimized tclIndex
authorAnders Kaseorg <andersk@mit.edu>
Wed, 16 Nov 2016 21:37:17 +0000 (16:37 -0500)
committerJunio C Hamano <gitster@pobox.com>
Wed, 22 Nov 2017 04:46:57 +0000 (13:46 +0900)
auto_mkindex expands wildcards in directory order, which depends on
the underlying filesystem.  To improve build reproducibility, sort the
list of *.tcl files in the Makefile.

The unoptimized loading case was previously fixed in gitgui-0.21.0~14
(git-gui: sort entries in tclIndex, 2015-01-26).

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Makefile

index fe30be38dc8c534cabf8a0f7145c41aecd1e6989..f94b3e13d6436969f35198b60e8b743d58c70d76 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -252,7 +252,7 @@ $(ALL_MSGFILES): %.msg : %.po
 lib/tclIndex: $(ALL_LIBFILES) GIT-GUI-VARS
        $(QUIET_INDEX)if echo \
          $(foreach p,$(PRELOAD_FILES),source $p\;) \
-         auto_mkindex lib '*.tcl' \
+         auto_mkindex lib $(patsubst lib/%,%,$(sort $(ALL_LIBFILES))) \
        | $(TCL_PATH) $(QUIET_2DEVNULL); then : ok; \
        else \
         echo >&2 "    * $(TCL_PATH) failed; using unoptimized loading"; \