aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukas Larsson <[email protected]>2018-06-11 11:12:35 +0200
committerLukas Larsson <[email protected]>2018-06-11 11:13:07 +0200
commit199095e7a49b57b7660fdd695139791d73fcf7c6 (patch)
tree5ee3154c0ab42d3d1c4e2aad52be1ab341ffca28
parent995c90f9537c29dcc86f07a613d67513fca7f1d7 (diff)
downloadotp-199095e7a49b57b7660fdd695139791d73fcf7c6.tar.gz
otp-199095e7a49b57b7660fdd695139791d73fcf7c6.tar.bz2
otp-199095e7a49b57b7660fdd695139791d73fcf7c6.zip
otp: Allow applications to opt out of github edit links
This is to be used by application like orber that live outside the main repository but still use the OTP build system to generate documentation.
-rw-r--r--make/otp_release_targets.mk9
1 files changed, 9 insertions, 0 deletions
diff --git a/make/otp_release_targets.mk b/make/otp_release_targets.mk
index 779aaa1a1e..ae4190808b 100644
--- a/make/otp_release_targets.mk
+++ b/make/otp_release_targets.mk
@@ -39,6 +39,8 @@ endif
_create_xml_dirs := $(shell mkdir -p $(XMLDIR))
XML_GEN_FILES+=$(patsubst %.xml,$(XMLDIR)/%.xml,$(XML_FILES))
+
+ifeq ($(strip $(NO_GITHUB_DOC_LINKS)),)
$(XMLDIR)/%.xml: %.xml
$(gen_verbose)escript $(DOCGEN)/priv/bin/github_link.escript $< \
"$(subst $(ERL_TOP)/,,$(CURDIR)/$^)" "NA" $@
@@ -46,6 +48,13 @@ $(XMLDIR)/%.xml: %.xml
$(XMLDIR)/%.xmlsrc: %.xmlsrc
$(gen_verbose)escript $(DOCGEN)/priv/bin/github_link.escript $< \
"$(subst $(ERL_TOP)/,,$(CURDIR)/$^)" "NA" $@
+else
+## Just copy the files if the application does not want github edit links
+$(XMLDIR)/%.xml: %.xml
+ $(gen_verbose)$(CP) $< $@
+$(XMLDIR)/%.xmlsrc: %.xmlsrc
+ $(gen_verbose)$(CP) $< $@
+endif
ifeq ($(TOPDOC),)