Update makefile in preparation for Documentation/config/*.txt

config.txt is going to be broken down in smaller pieces and put under Documentation/config directory. Update build rules to take these files into account. A dummy file is added to make sure wildcard expansion is predictable (depending on shell setting it could expand to nothing or becomes a path if config directory is empty). The file will be deleted once the move is over. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Nguyễn Thái Ngọc Duy committed Oct 27, 2018 at 08:22 UTC 76b993afd6dc7602aa6a14432c1136285308bc29
4 files changed +3 -3
Documentation/Makefile
+1 -1
@@ -285,7 +285,7 @@ docdep_prereqs = \
285 mergetools-list.made $(mergetools_txt) \
286 cmd-list.made $(cmds_txt)
287
288 -doc.dep : $(docdep_prereqs) $(wildcard *.txt) build-docdep.perl
288 +doc.dep : $(docdep_prereqs) $(wildcard *.txt) $(wildcard config/*.txt) build-docdep.perl
289 $(QUIET_GEN)$(RM) $@+ $@ && \
290 $(PERL_PATH) ./build-docdep.perl >$@+ $(QUIET_STDERR) && \
291 mv $@+ $@
Documentation/config/dummy.txt
Makefile
+1 -1
@@ -2068,7 +2068,7 @@ $(BUILT_INS): git$X
2068
2069 command-list.h: generate-cmdlist.sh command-list.txt
2070
2071 -command-list.h: $(wildcard Documentation/git*.txt) Documentation/*config.txt
2071 +command-list.h: $(wildcard Documentation/git*.txt) Documentation/*config.txt Documentation/config/*.txt
2072 $(QUIET_GEN)$(SHELL_PATH) ./generate-cmdlist.sh command-list.txt >$@+ && mv $@+ $@
2073
2074 SCRIPT_DEFINES = $(SHELL_PATH_SQ):$(DIFF_SQ):$(GIT_VERSION):\
generate-cmdlist.sh
+1 -1
@@ -80,7 +80,7 @@ print_config_list () {
80 cat <<EOF
81 static const char *config_name_list[] = {
82 EOF
83 - grep -h '^[a-zA-Z].*\..*::$' Documentation/*config.txt |
83 + grep -h '^[a-zA-Z].*\..*::$' Documentation/*config.txt Documentation/config/*.txt |
84 sed '/deprecated/d; s/::$//; s/, */\n/g' |
85 sort |
86 while read line