Restore runtime dependencies to documentation files

* Makefile.in (MAKE_DOC_FOR_DOCLANG): Remove unnecessary .PHONY
definitions for targets which will be encompassed by $(DOC).
(MAKE_DOC): Create a common target to to which to assign runtime
dependencies.
(misc-info-common, misc-dvi-common, misc-html-common)
(misc-pdf-common, misc-ps-common): Assign runtime dependencies
on Lisp etc. previously assigned to the bare targets now subject
to indirection.
This commit is contained in:
Po Lu 2026-06-01 12:15:04 +08:00
parent 6db4271ee8
commit 75d8e5773d

View file

@ -1147,12 +1147,14 @@ PSS = lispref-ps lispintro-ps emacs-ps misc-ps
DOCS = $(DVIS) $(HTMLS) $(INFOS) $(PDFS) $(PSS)
define MAKE_DOC_FOR_DOCLANG
.PHONY: $(1)-DOCLANG-$(2)
$(1)-DOCLANG-$(2):
$(1)-DOCLANG-$(2): $(1)-common
$$(MAKE) -C doc/$$(subst -, DOCLANG=$(2) ,$(1))
endef
define MAKE_DOC
# Define a target to which dependencies common to all of the doc files
# in this directory may be assigned.
$(1)-common:
$(1): $$(addprefix $(1)-DOCLANG-,$(DOCLANGS))
$$(foreach lang,$(DOCLANGS),$$(eval $$(call MAKE_DOC_FOR_DOCLANG,$(1),$$(lang))))
@ -1174,10 +1176,10 @@ ps: $(PSS)
# Depending on src is sufficient, but ends up being slow, since the
# uncompiled lisp/org/*.el files are used to build the .texi files
# (which can be slow even with the elc files).
misc-info: lisp
misc-info-common: lisp
# Using src rather than lisp because one is less likely to get unnecessary
# rebuilds of stuff that is not strictly necessary for generating manuals.
misc-dvi misc-html misc-pdf misc-ps: src
misc-dvi-common misc-html-common misc-pdf-common misc-ps-common: src
info-dir: ${srcdir}/info/dir