Documentation/Makefile: make doc.dep dependencies a variable again

Re-introduce a variable to declare what *.txt files need to be considered for the purposes of scouring files to generate a dependency graph of includes. When doc.dep was introduced in a5ae8e64cf (Fix documentation dependency generation., 2005-11-07) we had such a variable called TEXTFILES, but it was refactored away just a few commits after that in fb612d54c1 (Documentation: fix dependency generation., 2005-11-07). I'm planning to add more wildcards here, so let's bring it back. I'm not calling it TEXTFILES because we e.g. don't consider Documentation/technical/*.txt when generating the graph (they don't use includes). Let's instead call it DOC_DEP_TXT. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Ævar Arnfjörð Bjarmason committed Apr 9, 2021 at 17:02 UTC 19bcc73e70e05a9d346c5d488edbb7ce2b36c40f
1 file changed +5 -1
Documentation/Makefile
+5 -1
@@ -3,6 +3,7 @@ MAN1_TXT =
3 MAN5_TXT =
4 MAN7_TXT =
5 HOWTO_TXT =
6 +DOC_DEP_TXT =
7 TECH_DOCS =
8 ARTICLES =
9 SP_ARTICLES =
@@ -45,6 +46,9 @@ MAN7_TXT += gitworkflows.txt
46
47 HOWTO_TXT += $(wildcard howto/*.txt)
48
49 +DOC_DEP_TXT += $(wildcard *.txt)
50 +DOC_DEP_TXT += $(wildcard config/*.txt)
51 +
52 ifdef MAN_FILTER
53 MAN_TXT = $(filter $(MAN_FILTER),$(MAN1_TXT) $(MAN5_TXT) $(MAN7_TXT))
54 else
@@ -288,7 +292,7 @@ docdep_prereqs = \
292 mergetools-list.made $(mergetools_txt) \
293 cmd-list.made $(cmds_txt)
294
291 -doc.dep : $(docdep_prereqs) $(wildcard *.txt) $(wildcard config/*.txt) build-docdep.perl
295 +doc.dep : $(docdep_prereqs) $(DOC_DEP_TXT) build-docdep.perl
296 $(QUIET_GEN)$(RM) $@+ $@ && \
297 $(PERL_PATH) ./build-docdep.perl >$@+ $(QUIET_STDERR) && \
298 mv $@+ $@