[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] Integrate the Xen-API doc into the build.



# HG changeset patch
# User Ewan Mellor <ewan@xxxxxxxxxxxxx>
# Date 1169922401 0
# Node ID ea3c752045555180c2de41913e5efeabd424d0cf
# Parent  965cdfff68b04deba4078c89b9e01065bdb9b49e
Integrate the Xen-API doc into the build.

Signed-off-by: Ewan Mellor <ewan@xxxxxxxxxxxxx>
---
 docs/Docs.mk          |   12 ++++++++++++
 docs/Makefile         |   19 ++++++++-----------
 docs/xen-api/Makefile |   31 +++++++++++++++++++++++++------
 3 files changed, 45 insertions(+), 17 deletions(-)

diff -r 965cdfff68b0 -r ea3c75204555 docs/Docs.mk
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/docs/Docs.mk      Sat Jan 27 18:26:41 2007 +0000
@@ -0,0 +1,12 @@
+PS2PDF         := ps2pdf
+DVIPS          := dvips
+LATEX          := latex
+FIG2DEV                := fig2dev
+LATEX2HTML     := latex2html
+DOXYGEN                := doxygen
+POD2MAN                := pod2man
+DOT            := dot
+
+pkgdocdir      := /usr/share/doc/xen
+mandir         := /usr/share/man
+
diff -r 965cdfff68b0 -r ea3c75204555 docs/Makefile
--- a/docs/Makefile     Sat Jan 27 15:02:00 2007 +0000
+++ b/docs/Makefile     Sat Jan 27 18:26:41 2007 +0000
@@ -2,19 +2,9 @@
 
 XEN_ROOT=..
 include $(XEN_ROOT)/Config.mk
+include $(XEN_ROOT)/docs/Docs.mk
 
 VERSION                = xen-unstable
-
-PS2PDF         := ps2pdf
-DVIPS          := dvips
-LATEX          := latex
-FIG2DEV                := fig2dev
-LATEX2HTML     := latex2html
-DOXYGEN                := doxygen
-POD2MAN                := pod2man
-
-pkgdocdir      := /usr/share/doc/xen
-mandir         := /usr/share/man
 
 DOC_MAN5SRC    := $(wildcard man/*.pod.5)
 DOC_MAN1SRC    := $(wildcard man/*.pod.1)
@@ -32,6 +22,9 @@ all: build
 
 .PHONY: build
 build: ps pdf html man-pages
+       @if which $(DOT) 1>/dev/null 2>/dev/null ; then              \
+       $(MAKE) -C xen-api build ; else                              \
+        echo "Graphviz (dot) not installed; skipping xen-api." ; fi
        rm -f *.aux *.dvi *.bbl *.blg *.glo *.idx *.ilg *.log *.ind *.toc
 
 .PHONY: dev-docs
@@ -74,6 +67,7 @@ man5/%.5: man/%.pod.5 Makefile
 
 .PHONY: clean
 clean:
+       $(MAKE) -C xen-api clean
        rm -rf .word_count *.aux *.dvi *.bbl *.blg *.glo *.idx *~ 
        rm -rf *.ilg *.log *.ind *.toc *.bak core
        rm -rf $(GFX) ps pdf html
@@ -88,6 +82,9 @@ install: all
 install: all
        rm -rf $(DESTDIR)$(pkgdocdir)
        $(INSTALL_DIR) $(DESTDIR)$(pkgdocdir)
+
+       $(MAKE) -C xen-api install
+
        cp -dR ps $(DESTDIR)$(pkgdocdir)
        cp -dR pdf $(DESTDIR)$(pkgdocdir)
        $(INSTALL_DIR) $(DESTDIR)$(mandir)
diff -r 965cdfff68b0 -r ea3c75204555 docs/xen-api/Makefile
--- a/docs/xen-api/Makefile     Sat Jan 27 15:02:00 2007 +0000
+++ b/docs/xen-api/Makefile     Sat Jan 27 18:26:41 2007 +0000
@@ -1,22 +1,41 @@ TEX := $(wildcard *.tex)
+#!/usr/bin/make -f
+
+XEN_ROOT=../..
+include $(XEN_ROOT)/Config.mk
+include $(XEN_ROOT)/docs/Docs.mk
+
+
 TEX := $(wildcard *.tex)
 EPS := $(wildcard *.eps)
 EPSDOT := $(patsubst %.dot,%.eps,$(wildcard *.dot))
 
 .PHONY: all
-all: xenapi.pdf xenapi.ps
+all: build
+
+.PHONY: build
+build: xenapi.pdf xenapi.ps
+
+install:
+       $(INSTALL_DIR) $(DESTDIR)$(pkgdocdir)/ps
+       $(INSTALL_DIR) $(DESTDIR)$(pkgdocdir)/pdf
+
+       cp xenapi.ps $(DESTDIR)$(pkgdocdir)/ps
+       cp xenapi.pdf $(DESTDIR)$(pkgdocdir)/pdf
+
 
 xenapi.dvi: $(TEX) $(EPS) $(EPSDOT)
-       latex xenapi.tex
-       latex xenapi.tex
+       $(LATEX) xenapi.tex
+       $(LATEX) xenapi.tex
+       rm -f *.aux *.log
 
 %.pdf: %.ps
-       ps2pdf $< $@
+       $(PS2PDF) $< $@
 
 %.ps: %.dvi
-       dvips $< -o $@
+       $(DVIPS) $< -o $@
 
 %.eps: %.dot
-       dot -Tps $< >$@
+       $(DOT) -Tps $< >$@
 
 .PHONY: clean
 clean:

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.