OLD | NEW |
1 .SUFFIXES: .doc .tely .texi .ly | 1 .SUFFIXES: .doc .tely .texi .ly |
2 | 2 |
3 # TODO: fix hardcoded out/ ? | 3 # TODO: fix hardcoded out/ ? |
4 LYS_OUTPUT_OPTION= --lily-output-dir $(LYS_OUTPUT_DIR) | 4 LYS_OUTPUT_OPTION= --lily-output-dir $(LYS_OUTPUT_DIR) |
5 LYS_OUTPUT_DIR=$(top-build-dir)/out/lybook-db | 5 LYS_OUTPUT_DIR=$(top-build-dir)/out/lybook-db |
6 LILYPOND_BOOK_FLAGS += $(LYS_OUTPUT_OPTION) | 6 LILYPOND_BOOK_FLAGS += $(LYS_OUTPUT_OPTION) |
7 $(outdir)/%.latex: %.doc $(INIT_LY_SOURCES) $(SCHEME_SOURCES) | 7 $(outdir)/%.latex: %.doc $(INIT_LY_SOURCES) $(SCHEME_SOURCES) |
8 » LILYPOND_VERSION=$(TOPLEVEL_VERSION) PDFTEX=$(PDFTEX) PDFLATEX=$(PDFLATE
X) $(PYTHON) $(LILYPOND_BOOK) $(LILYPOND_BOOK_INCLUDES) --process='$(LILYPOND_BO
OK_PROCESS) $(LILYPOND_BOOK_LILYPOND_FLAGS)' --output=$(outdir) $(LILYPOND_BOOK_
FLAGS) --redirect-lilypond-output $< | 8 » LILYPOND_VERSION=$(TOPLEVEL_VERSION) \ |
| 9 » » TEX=$(PDFTEX) PDFTEX=$(PDFTEX) PDFLATEX=$(PDFLATEX) \ |
| 10 » » $(PYTHON) $(LILYPOND_BOOK) $(LILYPOND_BOOK_INCLUDES) \ |
| 11 » » --process='$(LILYPOND_BOOK_PROCESS) \ |
| 12 » » $(LILYPOND_BOOK_LILYPOND_FLAGS)' \ |
| 13 » » --output=$(outdir) $(LILYPOND_BOOK_FLAGS) \ |
| 14 » » --redirect-lilypond-output $< |
9 | 15 |
10 | 16 |
11 # This allows -j make option while making sure only one lilypond-book instance | 17 # This allows -j make option while making sure only one lilypond-book instance |
12 # is running at the same time, using GNU make's order-only prerequisites so | 18 # is running at the same time, using GNU make's order-only prerequisites so |
13 # as to not create superficial dependencies between unrelated manuals. | 19 # as to not create superficial dependencies between unrelated manuals. |
14 define CHAIN_RULE | 20 define CHAIN_RULE |
15 | $(i) | 21 | $(i) |
16 $(i):· | 22 $(i):· |
17 endef | 23 endef |
18 | 24 |
19 $(eval $(firstword $(TEXI_FILES_FROM_TELY)):\ | 25 $(eval $(firstword $(TEXI_FILES_FROM_TELY)):\ |
20 $(foreach i, $(wordlist 2, $(words $(TEXI_FILES_FROM_TELY)),\ | 26 $(foreach i, $(wordlist 2, $(words $(TEXI_FILES_FROM_TELY)),\ |
21 $(TEXI_FILES_FROM_TELY)),$(CHAIN_RULE))) | 27 $(TEXI_FILES_FROM_TELY)),$(CHAIN_RULE))) |
22 | 28 |
23 # don't do ``cd $(outdir)'', and assume that $(outdir)/.. is the src dir. | 29 # don't do ``cd $(outdir)'', and assume that $(outdir)/.. is the src dir. |
24 # it is not, for --srcdir builds | 30 # it is not, for --srcdir builds |
25 $(outdir)/%.texi: %.tely $(outdir)/version.itexi $(DOCUMENTATION_LOCALE_TARGET)
$(INIT_LY_SOURCES) $(SCHEME_SOURCES) | 31 $(outdir)/%.texi: %.tely $(outdir)/version.itexi $(DOCUMENTATION_LOCALE_TARGET)
$(INIT_LY_SOURCES) $(SCHEME_SOURCES) |
26 » LILYPOND_VERSION=$(TOPLEVEL_VERSION) PDFTEX=$(PDFTEX) PDFLATEX=$(PDFLATE
X) $(PYTHON) $(LILYPOND_BOOK) $(LILYPOND_BOOK_INCLUDES) --process='$(LILYPOND_BO
OK_PROCESS) $(LILYPOND_BOOK_LILYPOND_FLAGS)' --output=$(outdir) --format=$(LILYP
OND_BOOK_FORMAT) $(LILYPOND_BOOK_FLAGS) --redirect-lilypond-output $< | 32 » LILYPOND_VERSION=$(TOPLEVEL_VERSION) \ |
| 33 » » TEX=$(PDFTEX) PDFTEX=$(PDFTEX) PDFLATEX=$(PDFLATEX) \ |
| 34 » » $(PYTHON) $(LILYPOND_BOOK) $(LILYPOND_BOOK_INCLUDES) \ |
| 35 » » --process='$(LILYPOND_BOOK_PROCESS) \ |
| 36 » » $(LILYPOND_BOOK_LILYPOND_FLAGS)' \ |
| 37 » » --output=$(outdir) --format=$(LILYPOND_BOOK_FORMAT) \ |
| 38 » » $(LILYPOND_BOOK_FLAGS) --redirect-lilypond-output $< |
27 | 39 |
28 | 40 |
29 $(outdir)/%.texi: $(outdir)/%.tely $(outdir)/version.itexi $(DOCUMENTATION_LOCAL
E_TARGET) $(INIT_LY_SOURCES) $(SCHEME_SOURCES) | 41 $(outdir)/%.texi: $(outdir)/%.tely $(outdir)/version.itexi $(DOCUMENTATION_LOCAL
E_TARGET) $(INIT_LY_SOURCES) $(SCHEME_SOURCES) |
30 » LILYPOND_VERSION=$(TOPLEVEL_VERSION) PDFTEX=$(PDFTEX) PDFLATEX=$(PDFLATE
X) $(PYTHON) $(LILYPOND_BOOK) $(LILYPOND_BOOK_INCLUDES) --process='$(LILYPOND_BO
OK_PROCESS) $(LILYPOND_BOOK_INCLUDES) $(LILYPOND_BOOK_LILYPOND_FLAGS)' --output=
$(outdir) --format=$(LILYPOND_BOOK_FORMAT) $(LILYPOND_BOOK_FLAGS) --redirect-lil
ypond-output $< | 42 » LILYPOND_VERSION=$(TOPLEVEL_VERSION) \ |
| 43 » » TEX=$(PDFTEX) PDFTEX=$(PDFTEX) PDFLATEX=$(PDFLATEX) \ |
| 44 » » $(PYTHON) $(LILYPOND_BOOK) $(LILYPOND_BOOK_INCLUDES) \ |
| 45 » » --process='$(LILYPOND_BOOK_PROCESS) \ |
| 46 » » $(LILYPOND_BOOK_INCLUDES) $(LILYPOND_BOOK_LILYPOND_FLAGS)' \ |
| 47 » » --output=$(outdir) --format=$(LILYPOND_BOOK_FORMAT) \ |
| 48 » » $(LILYPOND_BOOK_FLAGS) --redirect-lilypond-output $< |
31 | 49 |
32 | 50 |
33 $(outdir)/%.html.omf: %.tely | 51 $(outdir)/%.html.omf: %.tely |
34 $(call GENERATE_OMF,html) | 52 $(call GENERATE_OMF,html) |
35 | 53 |
36 $(outdir)/%.pdf.omf: %.tely | 54 $(outdir)/%.pdf.omf: %.tely |
37 $(call GENERATE_OMF,pdf) | 55 $(call GENERATE_OMF,pdf) |
38 | 56 |
39 $(outdir)/%.html.omf: $(outdir)/%.texi | $(OUT_TEXINFO_MANUALS) | 57 $(outdir)/%.html.omf: $(outdir)/%.texi | $(OUT_TEXINFO_MANUALS) |
40 $(call GENERATE_OMF,html) | 58 $(call GENERATE_OMF,html) |
41 | 59 |
42 $(outdir)/%.pdf.omf: $(outdir)/%.texi | $(OUT_TEXINFO_MANUALS) | 60 $(outdir)/%.pdf.omf: $(outdir)/%.texi | $(OUT_TEXINFO_MANUALS) |
43 $(call GENERATE_OMF,pdf) | 61 $(call GENERATE_OMF,pdf) |
44 | 62 |
45 $(outdir)/others-did.itexi $(outdir)/we-wrote.itexi: $(outdir)/%.itexi: $(top-sr
c-dir)/Documentation/web/%.bib $(top-src-dir)/Documentation/lily-bib.bst | 63 $(outdir)/others-did.itexi $(outdir)/we-wrote.itexi: $(outdir)/%.itexi: $(top-sr
c-dir)/Documentation/web/%.bib $(top-src-dir)/Documentation/lily-bib.bst |
46 BSTINPUTS=$(top-src-dir)/Documentation/web/ $(buildscript-dir)/bib2texi
\ | 64 BSTINPUTS=$(top-src-dir)/Documentation/web/ $(buildscript-dir)/bib2texi
\ |
47 -s $(top-src-dir)/Documentation/lily-bib \ | 65 -s $(top-src-dir)/Documentation/lily-bib \ |
48 -o $(outdir)/$*.itexi \ | 66 -o $(outdir)/$*.itexi \ |
49 -q \ | 67 -q \ |
50 $(top-src-dir)/Documentation/web/$*.bib | 68 $(top-src-dir)/Documentation/web/$*.bib |
OLD | NEW |