8148617: top level make docs target does not generate javadocs for dynalink API
authorsundar
Sat, 30 Jan 2016 00:25:53 +0530
changeset 35369 a68e46d94261
parent 35368 e840ea7ac92d
child 35370 f9b430645a18
8148617: top level make docs target does not generate javadocs for dynalink API Reviewed-by: erikj, hannesw
make/Javadoc.gmk
make/common/NON_CORE_PKGS.gmk
--- a/make/Javadoc.gmk	Thu Jan 28 15:41:48 2016 -0800
+++ b/make/Javadoc.gmk	Sat Jan 30 00:25:53 2016 +0530
@@ -76,6 +76,7 @@
 TRACING_FIRST_COPYRIGHT_YEAR = 2008
 TREEAPI_FIRST_COPYRIGHT_YEAR = 2005
 NASHORNAPI_FIRST_COPYRIGHT_YEAR = 2014
+DYNALINKAPI_FIRST_COPYRIGHT_YEAR = 2015
 JNLP_FIRST_COPYRIGHT_YEAR = 1998
 PLUGIN2_FIRST_COPYRIGHT_YEAR = 2007
 JDKNET_FIRST_COPYRIGHT_YEAR = 2014
@@ -1215,6 +1216,60 @@
 
 #############################################################
 #
+# dynalinkapidocs
+#
+
+ALL_OTHER_TARGETS += dynalinkapidocs
+
+DYNALINKAPI_DOCDIR := $(JDK_API_DOCSDIR)/dynalink
+DYNALINKAPI2COREAPI := ../$(JDKJRE2COREAPI)
+DYNALINKAPI_DOCTITLE := Dynalink API
+DYNALINKAPI_WINDOWTITLE := Dynalink API
+DYNALINKAPI_HEADER := <strong>Dynalink API</strong>
+DYNALINKAPI_BOTTOM := $(call CommonBottom,$(DYNALINKAPI_FIRST_COPYRIGHT_YEAR))
+DYNALINKAPI_GROUPNAME := Packages
+DYNALINKAPI_REGEXP := jdk.dynalink.*
+# DYNALINKAPI_PKGS is located in NON_CORE_PKGS.gmk
+
+DYNALINKAPI_INDEX_HTML = $(DYNALINKAPI_DOCDIR)/index.html
+DYNALINKAPI_OPTIONS_FILE = $(DOCSTMPDIR)/dynalinkapi.options
+DYNALINKAPI_PACKAGES_FILE = $(DOCSTMPDIR)/dynalinkapi.packages
+
+dynalinkapidocs: $(DYNALINKAPI_INDEX_HTML)
+
+# Set relative location to core api document root
+$(DYNALINKAPI_INDEX_HTML): GET2DOCSDIR=$(DYNALINKAPI2COREAPI)/..
+
+# Run javadoc if the index file is out of date or missing
+$(DYNALINKAPI_INDEX_HTML): $(DYNALINKAPI_OPTIONS_FILE) $(DYNALINKAPI_PACKAGES_FILE) $(COREAPI_INDEX_FILE)
+	$(prep-javadoc)
+	$(call JavadocSummary,$(DYNALINKAPI_OPTIONS_FILE),$(DYNALINKAPI_PACKAGES_FILE))
+	$(JAVADOC_CMD_SMALL) -d $(@D) \
+	    @$(DYNALINKAPI_OPTIONS_FILE) @$(DYNALINKAPI_PACKAGES_FILE)
+
+# Create file with javadoc options in it
+$(DYNALINKAPI_OPTIONS_FILE):
+	$(prep-target)
+	@($(call COMMON_JAVADOCFLAGS) ; \
+          $(call COMMON_JAVADOCTAGS) ; \
+	  $(call OptionOnly,-Xdoclint:all) ; \
+	  $(call OptionPair,-sourcepath,$(RELEASEDOCS_SOURCEPATH)) ; \
+	  $(call OptionPair,-encoding,ascii) ; \
+	  $(call OptionPair,-doctitle,$(DYNALINKAPI_DOCTITLE)) ; \
+	  $(call OptionPair,-windowtitle,$(DYNALINKAPI_WINDOWTITLE) $(DRAFT_WINTITLE)); \
+	  $(call OptionPair,-header,$(DYNALINKAPI_HEADER)$(DRAFT_HEADER)) ; \
+	  $(call OptionPair,-bottom,$(DYNALINKAPI_BOTTOM)$(DRAFT_BOTTOM)) ; \
+	  $(call OptionTrip,-group,$(DYNALINKAPI_GROUPNAME),$(DYNALINKAPI_REGEXP)); \
+	  $(call OptionTrip,-linkoffline,$(DYNALINKAPI2COREAPI),$(COREAPI_DOCSDIR)/); \
+	) >> $@
+
+# Create a file with the package names in it
+$(DYNALINKAPI_PACKAGES_FILE): $(call PackageDependencies,$(DYNALINKAPI_PKGS))
+	$(prep-target)
+	$(call PackageFilter,$(DYNALINKAPI_PKGS))
+
+#############################################################
+#
 # sctpdocs
 #
 
--- a/make/common/NON_CORE_PKGS.gmk	Thu Jan 28 15:41:48 2016 -0800
+++ b/make/common/NON_CORE_PKGS.gmk	Sat Jan 30 00:25:53 2016 +0530
@@ -86,6 +86,12 @@
 
 NASHORNAPI_PKGS = jdk.nashorn.api.scripting \
     jdk.nashorn.api.tree
+   
+DYNALINKAPI_PKGS = jdk.dynalink \
+    jdk.dynalink.beans \
+    jdk.dynalink.linker \
+    jdk.dynalink.linker.support \
+    jdk.dynalink.support
 
 SMARTCARDIO_PKGS = javax.smartcardio