2012-01-02 19:07:04 +00:00
|
|
|
.SUFFIXES: # we don't need default suffix rules
|
2011-07-17 12:49:43 +00:00
|
|
|
ifeq ($(MAKELEVEL), 0)
|
|
|
|
$(error This make needs to be started as a sub-make from the toplevel directory.)
|
|
|
|
endif
|
2011-07-18 15:55:23 +00:00
|
|
|
.PHONY: all info html pdf card manual guide install clean cleanall clean-install
|
2011-07-17 12:49:43 +00:00
|
|
|
|
|
|
|
all: info html pdf card
|
|
|
|
|
|
|
|
info: org
|
|
|
|
|
|
|
|
html: org.html
|
|
|
|
|
|
|
|
pdf: org.pdf orgguide.pdf
|
|
|
|
|
|
|
|
card: orgcard.pdf orgcard_letter.pdf orgguide.pdf
|
|
|
|
|
|
|
|
manual guide::
|
|
|
|
$(RMR) $@ ; $(MKDIR) $@
|
|
|
|
manual:: org.texi
|
|
|
|
$(TEXI2HTML) -o $@ $<
|
|
|
|
../UTILITIES/mansplit.pl $@/*
|
|
|
|
guide:: orgguide.texi
|
|
|
|
$(TEXI2HTML) -o $@ $<
|
|
|
|
../UTILITIES/guidesplit.pl $@/*
|
|
|
|
|
2011-10-28 08:33:15 +00:00
|
|
|
git-describe.texi: org.texi
|
|
|
|
@echo "@c automatically generated, do not edit" > git-describe.texi
|
|
|
|
@echo "@set VERSION $(ORGVERSION) ($(GITVERSION))" >> git-describe.texi
|
|
|
|
@echo "@set DATE $(DATE)" >> git-describe.texi
|
|
|
|
|
2011-07-17 12:49:43 +00:00
|
|
|
|
|
|
|
install: org
|
2012-01-02 19:07:04 +00:00
|
|
|
if [ ! -d $(DESTDIR)$(infodir) ]; then $(MKDIR) $(DESTDIR)$(infodir); else true; fi ;
|
|
|
|
$(CP) org $(DESTDIR)$(infodir)
|
|
|
|
$(INSTALL_INFO) --infodir=$(DESTDIR)$(infodir) org
|
2011-07-17 12:49:43 +00:00
|
|
|
|
2011-07-18 19:05:52 +00:00
|
|
|
clean:
|
2011-07-18 15:55:23 +00:00
|
|
|
$(RM) org *.pdf *.html *_letter.tex \
|
2011-07-17 12:49:43 +00:00
|
|
|
*.aux *.cp *.cps *.dvi *.fn *.fns *.ky *.kys *.pg *.pgs \
|
2011-10-28 08:33:15 +00:00
|
|
|
*.toc *.tp *.tps *.vr *.vrs *.log *.html *.ps git-describe.texi
|
2011-07-18 19:05:52 +00:00
|
|
|
cleanall: clean
|
|
|
|
$(RMR) guide manual
|
2011-07-17 12:49:43 +00:00
|
|
|
|
2011-07-18 15:55:23 +00:00
|
|
|
clean-install:
|
2012-01-02 19:07:04 +00:00
|
|
|
$(RM) $(DESTDIR)$(infodir)/org*
|
|
|
|
$(INSTALL_INFO) --infodir=$(DESTDIR)$(infodir) --remove org
|
2011-07-18 15:55:23 +00:00
|
|
|
|
2011-07-17 12:49:43 +00:00
|
|
|
.SUFFIXES: .texi .tex .txt
|
|
|
|
|
|
|
|
%: %.texi
|
2011-10-28 08:33:15 +00:00
|
|
|
$(MAKE) git-describe.texi
|
2011-07-17 12:49:43 +00:00
|
|
|
$(MAKEINFO) --no-split $< -o $@
|
|
|
|
|
|
|
|
%.pdf: LC_ALL=C # work around a bug in texi2dvi
|
|
|
|
%.pdf: LANG=C # work around a bug in texi2dvi
|
|
|
|
%.pdf: %.texi
|
|
|
|
$(TEXI2PDF) $<
|
|
|
|
%.pdf: %.tex
|
|
|
|
PDFLATEX=$(PDFTEX) $(TEXI2PDF) $<
|
|
|
|
|
|
|
|
%.html: %.texi
|
|
|
|
$(TEXI2HTML) --no-split -o $@ $<
|
|
|
|
../UTILITIES/manfull.pl $@
|
|
|
|
|
|
|
|
%.txt: %.tex
|
|
|
|
perl ../UTILITIES/orgcard2txt.pl $< > $@
|
|
|
|
|
|
|
|
%_letter.tex: %.tex
|
2011-10-28 08:33:15 +00:00
|
|
|
$(SED) -e 's/\\pdflayout=(0l)/\\pdflayout=(1l)/' \
|
2011-07-17 12:49:43 +00:00
|
|
|
$< > $@
|