Merge branch 'drm-patches' of master.kernel.org:/pub/scm/linux/kernel/git/airlied...
[linux-drm-fsl-dcu.git] / Documentation / DocBook / Makefile
index 66e1cf733571ccc4122dcc745bf9c713ee6559b6..10b5cd6c54a03f1cf23a67eb227af37aa92b2edb 100644 (file)
@@ -9,7 +9,7 @@
 DOCBOOKS := wanbook.xml z8530book.xml mcabook.xml videobook.xml \
            kernel-hacking.xml kernel-locking.xml deviceiobook.xml \
            procfs-guide.xml writing_usb_driver.xml \
-           kernel-api.xml journal-api.xml lsm.xml usb.xml \
+           kernel-api.xml filesystems.xml lsm.xml usb.xml \
            gadget.xml libata.xml mtdnand.xml librs.xml rapidio.xml \
            genericirq.xml
 
@@ -41,7 +41,7 @@ psdocs: $(PS)
 PDF := $(patsubst %.xml, %.pdf, $(BOOKS))
 pdfdocs: $(PDF)
 
-HTML := $(patsubst %.xml, %.html, $(BOOKS))
+HTML := $(sort $(patsubst %.xml, %.html, $(BOOKS)))
 htmldocs: $(HTML)
 
 MAN := $(patsubst %.xml, %.9, $(BOOKS))
@@ -53,8 +53,8 @@ installmandocs: mandocs
 
 ###
 #External programs used
-KERNELDOC = scripts/kernel-doc
-DOCPROC   = scripts/basic/docproc
+KERNELDOC = $(srctree)/scripts/kernel-doc
+DOCPROC   = $(objtree)/scripts/basic/docproc
 
 XMLTOFLAGS = -m $(srctree)/Documentation/DocBook/stylesheet.xsl
 #XMLTOFLAGS += --skip-validation
@@ -152,6 +152,7 @@ quiet_cmd_db2man = MAN     $@
        @(which xmlto > /dev/null 2>&1) || \
         (echo "*** You need to install xmlto ***"; \
          exit 1)
+       $(Q)mkdir -p $(obj)/man
        $(call cmd,db2man)
        @touch $@
 
@@ -190,9 +191,13 @@ quiet_cmd_fig2png = FIG2PNG $@
 ###
 # Help targets as used by the top-level makefile
 dochelp:
-       @echo  '  Linux kernel internal documentation in different formats:'
-       @echo  '  xmldocs (XML DocBook), psdocs (Postscript), pdfdocs (PDF)'
-       @echo  '  htmldocs (HTML), mandocs (man pages, use installmandocs to install)'
+       @echo  ' Linux kernel internal documentation in different formats:'
+       @echo  '  htmldocs        - HTML'
+       @echo  '  installmandocs  - install man pages generated by mandocs'
+       @echo  '  mandocs         - man pages'
+       @echo  '  pdfdocs         - PDF'
+       @echo  '  psdocs          - Postscript'
+       @echo  '  xmldocs         - XML DocBook'
 
 ###
 # Temporary files left by various tools
@@ -208,11 +213,7 @@ clean-files := $(DOCBOOKS) \
        $(patsubst %.xml, %.9,    $(DOCBOOKS)) \
        $(C-procfs-example)
 
-clean-dirs := $(patsubst %.xml,%,$(DOCBOOKS))
-
-#man put files in man subdir - traverse down
-subdir- := man/
-
+clean-dirs := $(patsubst %.xml,%,$(DOCBOOKS)) man
 
 # Declare the contents of the .PHONY variable as phony.  We keep that
 # information in a variable se we can use it in if_changed and friends.