Skip to content

Commit 1a7e55f

Browse files
committed
mk: Fix warnings about duplicated rules
The footer.tex rule didn't depend on $(1) of the macro it was being defined in, so it was getting duplicated, causing many warnings.
1 parent 167bfaf commit 1a7e55f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

mk/docs.mk

+4-4
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,10 @@ SHOULD_BUILD_PDF_DOC_$(1) = 1
147147
endef
148148
$(foreach docname,$(PDF_DOCS),$(eval $(call DEF_SHOULD_BUILD_PDF_DOC,$(docname))))
149149

150+
doc/footer.tex: $(D)/footer.inc | doc/
151+
@$$(call E, pandoc: $$@)
152+
$$(CFG_PANDOC) --from=html --to=latex $$< --output=$$@
153+
150154
define DEF_DOC
151155

152156
# HTML (rustdoc)
@@ -163,10 +167,6 @@ doc/$(1).epub: $$(D)/$(1).md | doc/
163167
@$$(call E, pandoc: $$@)
164168
$$(CFG_PANDOC) $$(PANDOC_EPUB_OPTS) $$< --output=$$@
165169

166-
doc/footer.tex: $(D)/footer.inc | doc/
167-
@$$(call E, pandoc: $$@)
168-
$$(CFG_PANDOC) --from=html --to=latex $$< --output=$$@
169-
170170
# PDF (md =(pandoc)=> tex =(pdflatex)=> pdf)
171171
DOC_TARGETS += doc/$(1).tex
172172
doc/$(1).tex: $$(D)/$(1).md doc/footer.tex doc/version.tex | doc/

0 commit comments

Comments
 (0)