Skip to content

Commit

Permalink
otp: Fix release of man pages
Browse files Browse the repository at this point in the history
The wildcard in release_man_spec is run before the 'man'
dependency, so it would return empty even when the man
dependency would create some man pages. This meant that
doing only 'make release_docs' did not release any man
pages.
  • Loading branch information
garazdawi committed Sep 2, 2024
1 parent 0678aab commit 7d84491
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions make/doc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -78,18 +78,18 @@ $(HTMLDIR)/index.html: $(HTML_DEPS) docs.exs $(ERL_TOP)/make/ex_doc.exs

html: $(HTMLDIR)/index.html

$(TYPES):

clean clean_docs: clean_html
rm -rf $(EXTRA_FILES)

man: $(MAN1_PAGES)

MARKDOWN_TO_MAN=$(ERL_TOP)/make/markdown_to_man.escript

man1/%.1: references/%_cmd.md $(MARKDOWN_TO_MAN)
escript$(EXEEXT) $(MARKDOWN_TO_MAN) -o $(MAN1DIR) $<

$(TYPES):

clean clean_docs: clean_html
rm -rf $(EXTRA_FILES)

# ----------------------------------------------------
# Release Target
# ----------------------------------------------------
Expand All @@ -106,17 +106,18 @@ ifneq ($(CHUNK_FILES),)
$(INSTALL_DATA) $(CHUNK_FILES) "$(RELSYSDIR)/doc/chunks"
endif

release_man_spec: man
ifneq ($(MAN1_DEPS),)
$(INSTALL_DIR) "$(RELSYS_MANDIR)/man1"
$(INSTALL_DIR_DATA) "$(MAN1DIR)" "$(RELSYS_MANDIR)/man1"
endif

release_docs_spec: $(DOC_TARGETS:%=release_%_spec)
ifneq ($(STANDARDS),)
$(INSTALL_DIR) "$(RELEASE_PATH)/doc/standard"
$(INSTALL_DATA) $(STANDARDS) "$(RELEASE_PATH)/doc/standard"
endif

release_man_spec: man
ifneq ($(wildcard man1/*.1),)
$(INSTALL_DIR) "$(RELSYS_MANDIR)/man1"
$(INSTALL_DIR_DATA) "$(MAN1DIR)" "$(RELSYS_MANDIR)/man1"
endif

release_spec:

Expand Down

0 comments on commit 7d84491

Please sign in to comment.