ia64/xen-unstable

view docs/Makefile @ 7556:6304291cf08b

Print out MFN in audit code, for debugging purposes.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
author emellor@leeni.uk.xensource.com
date Sun Oct 30 13:24:45 2005 +0100 (2005-10-30)
parents 06d84bf87159
children d49fd494963e
line source
1 #!/usr/bin/make -f
3 INSTALL = install
4 INSTALL_DIR = $(INSTALL) -d -m0755
6 PS2PDF := ps2pdf
7 DVIPS := dvips
8 LATEX := latex
9 FIG2DEV := fig2dev
10 LATEX2HTML := latex2html
11 DOXYGEN := doxygen
13 pkgdocdir := /usr/share/doc/xen
15 DOC_TEX := src/user.tex src/interface.tex
16 DOC_PS := $(patsubst src/%.tex,ps/%.ps,$(DOC_TEX))
17 DOC_PDF := $(patsubst src/%.tex,pdf/%.pdf,$(DOC_TEX))
18 DOC_HTML := $(patsubst src/%.tex,html/%/index.html,$(DOC_TEX))
20 GFX = $(patsubst %.fig, %.eps, $(wildcard figs/*.fig))
22 .PHONY: all build dev-docs python-dev-docs ps pdf html clean install
24 all: build
25 build: ps pdf html
26 rm -f *.aux *.dvi *.bbl *.blg *.glo *.idx *.ilg *.log *.ind *.toc
28 dev-docs: python-dev-docs
30 ps: $(DOC_PS)
32 pdf: $(DOC_PDF)
34 html:
35 @if which $(LATEX2HTML) 1>/dev/null 2>/dev/null; then \
36 $(MAKE) $(DOC_HTML); fi
38 python-dev-docs:
39 @mkdir -v -p api/tools/python
40 @if which $(DOXYGEN) 1>/dev/null 2>/dev/null; then \
41 echo "Running doxygen to generate Python tools APIs ... "; \
42 $(DOXYGEN) Doxyfile; \
43 $(MAKE) -C api/tools/python/latex ; else \
44 echo "Doxygen not installed; skipping python-dev-docs."; fi
46 clean:
47 rm -rf .word_count *.aux *.dvi *.bbl *.blg *.glo *.idx *~
48 rm -rf *.ilg *.log *.ind *.toc *.bak core
49 rm -rf $(GFX) ps pdf html
50 rm -rf api
52 install: all
53 rm -rf $(DESTDIR)$(pkgdocdir)
54 $(INSTALL_DIR) $(DESTDIR)$(pkgdocdir)
55 cp -dR ps $(DESTDIR)$(pkgdocdir)
56 cp -dR pdf $(DESTDIR)$(pkgdocdir)
57 [ ! -d html ] || cp -dR html $(DESTDIR)$(pkgdocdir)
59 pdf/%.pdf: ps/%.ps
60 $(INSTALL_DIR) $(@D)
61 $(PS2PDF) $< $@.new
62 mv $@.new $@
64 ps/%.ps: %.dvi
65 $(INSTALL_DIR) $(@D)
66 $(DVIPS) -Ppdf -G0 -o $@.new $<
67 mv $@.new $@
69 %.dvi: src/%.tex $(GFX)
70 $(LATEX) $< >/dev/null
71 if [ -e $*.toc ] ; then $(LATEX) $< >/dev/null ; fi
73 %.eps: %.fig
74 $(FIG2DEV) -L eps $< $@
76 html/%/index.html: src/%.tex
77 $(INSTALL_DIR) $(@D)
78 $(LATEX2HTML) -split 0 -show_section_numbers -toc_depth 3 -nonavigation \
79 -numbered_footnotes -local_icons -noinfo -math -dir $(@D) \
80 $< 1>/dev/null 2>/dev/null