]> git.saurik.com Git - apt.git/blob - doc/makefile
0cb135c7b75725d358e5b5c3d6463f3e1d4d487f
[apt.git] / doc / makefile
1 # -*- make -*-
2 BASE=..
3 SUBDIR=doc
4 SUBDIRS= $(dir $(wildcard */makefile))
5
6 # Bring in the default rules
7 include ../buildlib/defaults.mak
8
9 # Debian Doc SGML Documents
10 SOURCE = $(wildcard *.sgml)
11 DEBIANDOC_HTML_OPTIONS=-l en
12 include $(DEBIANDOC_H)
13
14 # XML man pages
15 SOURCE = apt-cache.8 apt-get.8 apt-cdrom.8 apt.conf.5 sources.list.5 \
16 apt-config.8 apt_preferences.5 \
17 apt-sortpkgs.1 apt-ftparchive.1 apt-extracttemplates.1 \
18 apt-key.8 apt-secure.8 apt-mark.8
19 INCLUDES = apt.ent
20 include $(XML_MANPAGE_H)
21
22 # Examples
23 SOURCE = examples/apt.conf examples/sources.list examples/configure-index examples/apt-https-method-example.conf
24 TO = $(DOC)
25 TARGET = binary
26 include $(COPY_H)
27
28 #.PHONY: headers library clean veryclean all binary program doc doc.pt_BR doc.fr
29 doc:
30 for dir in $(SUBDIRS); do\
31 $(MAKE) -C $$dir $@; \
32 done
33
34 clean: clean-subdirs
35 veryclean: veryclean-subdirs
36
37 clean-subdirs:
38 for dir in $(SUBDIRS); do\
39 $(MAKE) -C $$dir clean; \
40 done
41
42 veryclean-subdirs:
43 for dir in $(SUBDIRS); do\
44 $(MAKE) -C $$dir veryclean; \
45 done
46 # FIXME remove created sgml files, but preserve all
47 # which are "left over" from older systems.
48 # After completing the transition this should be handled
49 # in the po4a-manpage makefile for all translations
50 for dir in $(subst /addendum/,, $(dir $(wildcard */addendum/*))); do\
51 rm -f $$dir/offline.$$dir.sgml; \
52 rm -f $$dir/guide.$$dir.sgml; \
53 done
54
55 ifdef PO4A
56 doc: po4a
57
58 clean: po4a-clean
59
60 .PHONY: update-po po4a
61 update-po:
62 po4a --previous --no-backups --force --no-translations po4a.conf
63
64 po4a-clean:
65 po4a --previous --rm-backups --rm-translations po4a.conf
66
67 po4a:
68 po4a --previous --no-backups po4a.conf
69 endif
70
71 ifdef DOXYGEN
72 DOXYGEN_SOURCES = $(shell find $(BASE)/apt-pkg -not -name .\\\#* -and \( -name \*.cc -or -name \*.h \) )
73
74 clean: doxygen-clean
75
76 doxygen-clean:
77 rm -fr $(BUILD)/doc/doxygen
78 rm -f $(BUILD)/doc/doxygen-stamp
79
80 $(BUILD)/doc/Doxyfile: Doxyfile.in
81 (cd $(BUILD) && ./config.status doc/Doxyfile)
82
83 $(BUILD)/doc/doxygen-stamp: $(DOXYGEN_SOURCES) $(BUILD)/doc/Doxyfile
84 rm -fr $(BUILD)/doc/doxygen
85 $(DOXYGEN) $(BUILD)/doc/Doxyfile
86 touch $(BUILD)/doc/doxygen-stamp
87
88 doc: $(BUILD)/doc/doxygen-stamp
89
90 endif