summaryrefslogtreecommitdiff
path: root/doc/Makefile.in
blob: ba34b170a4a48e6fff324830e75d857ff819b445 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
VPATH		= @srcdir@
srcdir		= @srcdir@
top_srcdir	= @top_srcdir@

SUBDIRS		= ja sv

include ../Makefile.conf

MAN5PAGES	= deb-control.5 deb-old.5 deb.5

all: internals.html all-recursive

clean: clean-recursive
	$(RM) $(srcdir)/manuals-version
	$(RM) -rf internals.html/

distclean: clean distclean-recursive
	$(RM) Makefile

install: install-doc

manuals-version: $(top_srcdir)/version-nr
	set -e ; v=`sed -ne '1s/.*(\(.*\)).*/\1/' $(srcdir)/ChangeLog` ; \
	echo "<!entity manuals-version \"$$v\">" > $@
	echo "<!entity dpkg-version \"$(VERSION)\">" >> $@

internals.html: internals.sgml manuals-version
	debiandoc2html -n -D. $<

install-doc: install-doc-recursive
	$(mkinstalldirs) $(DESTDIR)$(man5dir) 
	set -e ; for i in $(MAN5PAGES) ; do \
		if test -f $$i ; then d= ; else d="$(srcdir)/" ; fi ; \
		$(INSTALL_DATA) $$d$$i $(DESTDIR)$(man5dir) ; \
	done
	$(mkinstalldirs) $(DESTDIR)$(docdir)/internals/
	set -e ; for i in internals.html/* ; do \
		bn=`basename $$i` ; \
		$(INSTALL_DATA) $$i $(DESTDIR)$(docdir)/internals/$$bn ; \
	done
	$(INSTALL_DATA) $(srcdir)/ChangeLog $(DESTDIR)$(docdir)/ChangeLog.manuals
	set -e ; for i in ChangeLog THANKS TODO ; do \
		$(INSTALL_DATA) $(top_srcdir)/$$i $(DESTDIR)$(docdir) ; \
	done
	$(INSTALL_DATA) $(top_srcdir)/COPYING $(DESTDIR)$(copyingfile)

all-recursive install-recursive install-doc-recursive clean-recursive distclean-recursive:
	set -e ; target=`echo $@ | $(SED) s/-recursive//`; \
		for s in $(SUBDIRS) ; do \
		$(MAKE) $(MFLAGS) -C $$s $$target ; \
	done;

.PHONY: all clean distclean install install-doc
.PHONY: all-recursive clean-recursive distclean-recursive install-recursive
.PHONY: install-doc-recursive