4 SUBDIRS= $(dir $(wildcard */makefile))
6 # Bring in the default rules
7 include ../buildlib/defaults.mak
9 # Debian Doc SGML Documents
10 SOURCE = $(wildcard *.sgml)
11 DEBIANDOC_HTML_OPTIONS=-l en.UTF-8
12 include $(DEBIANDOC_H)
14 # Do not use XMLTO, build the manpages directly with XSLTPROC
16 # generate a list of accepted man page translations
17 SOURCE = $(patsubst %.xml,%,$(wildcard *.?.xml))
19 STYLESHEET=manpage-style.xsl
21 LOCAL := manpage-$(firstword $(SOURCE))
22 $(LOCAL)-LIST := $(SOURCE)
24 # Install generation hooks
26 veryclean: veryclean/$(LOCAL)
28 $($(LOCAL)-LIST) :: % : %.xml $(INCLUDES)
29 echo Creating man page $@
30 $(XSLTPROC) -o $@ $(STYLESHEET) $<
33 .PHONY: veryclean/$(LOCAL)
39 # Chain to the manpage rule
44 SOURCE = examples/apt.conf examples/sources.list examples/configure-index examples/apt-https-method-example.conf
49 .PHONY: clean clean-subdirs veryclean veryclean-subdirs all binary doc
51 for i in $(shell ls po/*.po | sed -r 's#po/([a-z]+[A-Z_]*).po#\1#'); do \
52 test -d $$i || mkdir $$i; \
53 test -f $$i/makefile || sed "s#@@LANG@@#$$i#" lang.makefile > $$i/makefile; \
58 veryclean: veryclean-subdirs
61 for dir in $(SUBDIRS); do\
62 $(MAKE) -C $$dir clean; \
66 for dir in $(SUBDIRS); do\
75 .PHONY: update-po po4a stats
77 po4a --previous --no-backups --force --no-translations po4a.conf
80 po4a --previous --rm-backups --rm-translations po4a.conf
83 po4a --previous --no-backups po4a.conf
86 for i in po/*.po; do echo -n "$$i: "; msgfmt --statistics $$i; done
91 DOXYGEN_SOURCES = $(shell find $(BASE)/apt-pkg -not -name .\\\#* -and \( -name \*.cc -or -name \*.h \) )
96 rm -fr $(BUILD)/doc/doxygen
97 rm -f $(BUILD)/doc/doxygen-stamp
99 $(BUILD)/doc/Doxyfile: Doxyfile.in
100 (cd $(BUILD) && ./config.status doc/Doxyfile)
102 $(BUILD)/doc/doxygen-stamp: $(DOXYGEN_SOURCES) $(BUILD)/doc/Doxyfile
103 rm -fr $(BUILD)/doc/doxygen
104 mkdir $(BUILD)/doc/doxygen # some versions seem to not create this directory #628799
105 $(DOXYGEN) $(BUILD)/doc/Doxyfile
106 touch $(BUILD)/doc/doxygen-stamp
108 doc: $(BUILD)/doc/doxygen-stamp