Makefile 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. include debian/rules
  2. policy.sgml: version.ent
  3. menu-policy.sgml: version.ent
  4. perl-policy.sgml: version.ent
  5. %.txt: %.org
  6. $(EMACS) --batch -Q -l ./README-css.el -l org --visit $^ \
  7. --funcall org-ascii-export-to-ascii
  8. test "$@" != "README.txt" || \
  9. perl -pli -e 's,./Process.org,Process.txt,g' $@
  10. %.html: %.org
  11. $(EMACS) --batch -Q -l ./README-css.el -l org --visit $^ \
  12. --funcall org-html-export-to-html
  13. %.validate: %
  14. onsgmls -wall -gues $<
  15. %.html/index.html: %.sgml
  16. LANG=C debiandoc2html $<
  17. %-1.html: %.sgml
  18. LANG=C debiandoc2html -1 -b $*-1d $< && \
  19. mv $*-1d.html/index.html $*-1.html && \
  20. rmdir $*-1d.html
  21. %.html.tar.gz: %.html/index.html
  22. GZIP=-n9 tar -czf $(<:/index.html=.tar.gz) $(<:/index.html=)
  23. %.txt: %.sgml
  24. LANG=C debiandoc2text $<
  25. %.txt.gz: %.txt
  26. gzip -ncf9 $< > $@
  27. %.ps: %.sgml
  28. LANG=C debiandoc2latexps $<
  29. %.ps.gz: %.ps
  30. gzip -ncf9 $< > $@
  31. %.pdf: %.sgml
  32. LANG=C debiandoc2latexpdf $<
  33. %.pdf.gz: %.pdf
  34. gzip -ncf9 $< > $@
  35. # This is a temporary hack to fold the upgrading-checklist into the Policy
  36. # HTML directory so that it can be deployed alongside Policy on
  37. # www.debian.org in a way that lets the cross-document links work properly.
  38. # The correct solution is to make upgrading-checklist an appendix of Policy,
  39. # which will probably be done as part of a general conversion to DocBook.
  40. policy.html.tar.gz:: policy.html/upgrading-checklist.html
  41. policy.html/upgrading-checklist.html: upgrading-checklist-1.html \
  42. policy.html/index.html
  43. cp -p $< $@
  44. # convenience aliases :)
  45. html: policy.html/index.html
  46. html-1: policy-1.html
  47. txt text: policy.txt
  48. ps: policy.ps
  49. pdf: policy.pdf
  50. policy: html txt ps pdf
  51. leavealone := $(FHS_HTML) $(FHS_FILES) $(FHS_ARCHIVE) \
  52. libc6-migration.txt
  53. .PHONY: distclean
  54. distclean:
  55. rm -rf $(filter-out $(leavealone),$(wildcard *.html))
  56. rm -f $(filter-out $(leavealone),$(wildcard *.txt *.txt.gz *.html.tar.gz *.pdf *.ps))
  57. rm -f *.lout* lout.li *.sasp* *.tex *.aux *.toc *.idx *.log *.out *.dvi *.tpt
  58. rm -f `find . -name "*~" -o -name "*.bak" -o -name ".#*" -o -name core`
  59. rm -f version.ent
  60. rm -f *.rej *.orig
  61. # if a rule bombs out, delete the target
  62. .DELETE_ON_ERROR:
  63. # no default suffixes work here, don't waste time on them
  64. .SUFFIXES: