[ Nicolas François ]
[ntk/apt.git] / doc / makefile
1 # -*- make -*-
2 BASE=..
3 SUBDIR=doc
4 SUBDIRS= fr ja pl pt_BR es
5
6 # Bring in the default rules
7 include ../buildlib/defaults.mak
8
9 # Debian Doc SGML Documents
10 SOURCE = dpkg-tech.sgml design.sgml files.sgml guide.sgml guide.it.sgml \
11 cache.sgml method.sgml offline.sgml
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: po4a
30 for dir in $(SUBDIRS); do\
31 $(MAKE) -C $$dir $@; \
32 done
33
34 .PHONY: update-po po4a
35 update-po:
36 po4a --previous --no-backups --force --no-translations po4a.conf
37
38 clean: po4a-clean clean-subdirs
39
40 clean-subdirs:
41 for dir in $(SUBDIRS); do\
42 $(MAKE) -C $$dir $@; \
43 done
44
45 po4a-clean:
46 po4a --previous --rm-backups --rm-translations po4a.conf
47
48 po4a:
49 po4a --previous --no-backups po4a.conf
50
51 ifdef DOXYGEN
52 DOXYGEN_SOURCES = $(shell find $(BASE)/apt-pkg -not -name .\\\#* -and \( -name \*.cc -or -name \*.h \) )
53
54 clean: doxygen-clean
55
56 doxygen-clean:
57 rm -fr $(BUILD)/doc/doxygen
58 rm -f $(BUILD)/doc/doxygen-stamp
59
60 $(BUILD)/doc/Doxyfile: Doxyfile.in
61 (cd $(BUILD) && ./config.status doc/Doxyfile)
62
63 $(BUILD)/doc/doxygen-stamp: $(DOXYGEN_SOURCES) $(BUILD)/doc/Doxyfile
64 rm -fr $(BUILD)/doc/doxygen
65 $(DOXYGEN) $(BUILD)/doc/Doxyfile
66 touch $(BUILD)/doc/doxygen-stamp
67
68 doc: $(BUILD)/doc/doxygen-stamp
69
70 endif