Makefile 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. ifeq ($(MAKELEVEL), 0)
  2. $(error This make needs to be started as a sub-make from the toplevel directory.)
  3. endif
  4. .PHONY: all info html pdf card manual guide install clean cleanall
  5. all: info html pdf card
  6. info: org
  7. html: org.html
  8. pdf: org.pdf orgguide.pdf
  9. card: orgcard.pdf orgcard_letter.pdf orgguide.pdf
  10. manual guide::
  11. $(RMR) $@ ; $(MKDIR) $@
  12. manual:: org.texi
  13. $(TEXI2HTML) -o $@ $<
  14. ../UTILITIES/mansplit.pl $@/*
  15. guide:: orgguide.texi
  16. $(TEXI2HTML) -o $@ $<
  17. ../UTILITIES/guidesplit.pl $@/*
  18. install: org
  19. if [ ! -d $(infodir) ]; then $(MKDIR) $(infodir); else true; fi ;
  20. $(CP) org $(infodir)
  21. $(INSTALL_INFO) --infodir=$(infodir) org
  22. clean cleanall:
  23. $(RM) dir org *.pdf *.html *_letter.tex \
  24. *.aux *.cp *.cps *.dvi *.fn *.fns *.ky *.kys *.pg *.pgs \
  25. *.toc *.tp *.tps *.vr *.vrs *.log *.html *.ps
  26. .SUFFIXES: # we don't need default suffix rules
  27. .SUFFIXES: .texi .tex .txt
  28. %: %.texi
  29. $(MAKEINFO) --no-split $< -o $@
  30. %.pdf: LC_ALL=C # work around a bug in texi2dvi
  31. %.pdf: LANG=C # work around a bug in texi2dvi
  32. %.pdf: %.texi
  33. $(TEXI2PDF) $<
  34. %.pdf: %.tex
  35. PDFLATEX=$(PDFTEX) $(TEXI2PDF) $<
  36. %.html: %.texi
  37. $(TEXI2HTML) --no-split -o $@ $<
  38. ../UTILITIES/manfull.pl $@
  39. %.txt: %.tex
  40. perl ../UTILITIES/orgcard2txt.pl $< > $@
  41. %_letter.tex: %.tex
  42. perl -pe 's/\\pdflayout=\(0l\)/\\pdflayout=(1l)/' \
  43. $< > $@