Makefile
changeset 57 94e1b2d0bd31
parent 50 0bda4161d1b9
child 77 c2bad6178c65
--- a/Makefile	Thu Sep 11 20:01:40 2014 +0300
+++ b/Makefile	Mon Sep 15 02:49:02 2014 +0300
@@ -88,12 +88,16 @@
 
 DIST_DIR = $(fullpkgname)
 
-WWW_FILES := $(wildcard *.js) $(wildcard *.html)
+JS_FILES := $(wildcard *.js)
+HTML_FILES := $(wildcard *.html)
+WWW_FILES := $(JS_FILES) $(HTML_FILES)
 
 DIST_FILES = $(WWW_FILES) README.rst VERSION
 
 DIST_TARBALLS = $(DIST_DIR).tar.gz $(DIST_DIR).zip
 
+JSDOC_DIR := jsdoc
+
 ################################################################
 # Deploy targets.
 
@@ -199,6 +203,10 @@
 echo; \
 sed -n -e '/^[[:alnum:]_-]*:/{s=^\(.*\):.*=  \1=;p;}' $(BUILD_SCRIPTS)
 
+.PHONY: jsdoc
+jsdoc:
+	jsdoc -a -p -d=$(JSDOC_DIR) $(JS_FILES)
+
 ################################################################
 # Clean targets.
 
@@ -208,4 +216,5 @@
 
 .PHONY: clean
 clean:
-	rm -rf $(DIST_DIR) $(DIST_TARBALLS)
+	rm -rf $(JSDOC_DIR) $(DIST_DIR) $(DIST_TARBALLS)
+