Clarify the banned dependencies between main and non-main
[debian-policy.git] / Makefile
blob5d8931a48520aed5a247058eb3da40ad5e3aba88
1 include debian/rules
3 policy.sgml: version.ent
4 menu-policy.sgml: version.ent
5 mime-policy.sgml: version.ent
6 perl-policy.sgml: version.ent
8 ifneq (,$(strip $(HAVE_ORG_EMACS)))
9 %.txt: %.org
10 $(EMACS) --batch -Q -l ./README-css.el -l org -l org-ascii --visit $^ \
11 --funcall org-export-as-ascii >/dev/null 2>&1
12 test "$@" != "README.txt" || \
13 perl -pli -e 's,./Process.org,Process.txt,g' $@
14 %.html: %.org
15 $(EMACS) --batch -Q -l ./README-css.el -l org --visit $^ \
16 --funcall org-export-as-html-batch >/dev/null 2>&1
17 endif
19 %.validate: %
20 nsgmls -wall -gues $<
22 %.html/index.html: %.sgml
23 LANG=C debiandoc2html $<
25 %-1.html: %.sgml
26 LANG=C debiandoc2html -1 -b $*-1d $< && \
27 mv $*-1d.html/index.html $*-1.html && \
28 rmdir $*-1d.html
30 %.html.tar.gz: %.html/index.html
31 tar -czf $(<:/index.html=.tar.gz) $(<:/index.html=)
33 %.txt: %.sgml
34 LANG=C debiandoc2text $<
36 %.txt.gz: %.txt
37 gzip -cf9 $< > $@
39 %.ps: %.sgml
40 LANG=C debiandoc2latexps $<
42 %.ps.gz: %.ps
43 gzip -cf9 $< > $@
45 %.pdf: %.sgml
46 LANG=C debiandoc2latexpdf $<
48 %.pdf.gz: %.pdf
49 gzip -cf9 $< > $@
51 # convenience aliases :)
52 html: policy.html/index.html
53 html-1: policy-1.html
54 txt text: policy.txt
55 ps: policy.ps
56 pdf: policy.pdf
57 policy: html txt ps pdf
59 leavealone := $(FHS_HTML) $(FHS_FILES) $(FHS_ARCHIVE) \
60 libc6-migration.txt
62 .PHONY: distclean
63 distclean:
64 rm -rf $(filter-out $(leavealone),$(wildcard *.html))
65 rm -f $(filter-out $(leavealone),$(wildcard *.txt *.txt.gz *.html.tar.gz *.pdf *.ps))
66 rm -f *.lout* lout.li *.sasp* *.tex *.aux *.toc *.idx *.log *.out *.dvi *.tpt
67 rm -f `find . -name "*~" -o -name "*.bak" -o -name ".#*" -o -name core`
68 rm -f version.ent
69 rm -f *.rej *.orig
71 # if a rule bombs out, delete the target
72 .DELETE_ON_ERROR:
73 # no default suffixes work here, don't waste time on them
74 .SUFFIXES: