Am Freitag, 15. Mai 2009 12:55:08 schrieb John Mandereau:
> MOVEMENTS=I II III IV
>
> # define targets mvI ... mvIV
>
> # maybe need to be surrounded by $(eval ...)
>
> $(foreach m, MOVEMENTS, $(call movement_pdf_target,$(m))
>
> parts: $(foreach m, MOVEMENTS, mv$(m))
Shouldn't this be rather done with prerequisites, variable substitutions and
some generic rules?
I'm attaching one of my makefiles, which is not perfect, either, but it works
very well for my scores.
> ###
>
> Also, some people prefer not to call the viewer by default, but that's
> personal
> taste and depends on your viewer. One possibility is to enclose viewer
> commands
> within a 'ifneq ($(NOAUTOVIEW),)' block, so that viewer calls can be
> disabled
> by calling "make NOAUTOVIEW=1 ...".
It really depends on the viewer. I'm using okular and it reloads the PDF file
when it has changed, so starting another instance is just annoying...
Having to use a make variable on the command line to get sane behavior is even
more annoying.
Cheers,
Reinhold
--
------------------------------------------------------------------
Reinhold Kainhofer, [email protected], http://reinhold.kainhofer.com/
* Financial & Actuarial Math., Vienna Univ. of Technology, Austria
* http://www.fam.tuwien.ac.at/, DVR: 0005886
* LilyPond, Music typesetting, http://www.lilypond.org
SRCS = Pembaur_VierteLateinischeMesse_01_Kyrie.ly Pembaur_VierteLateinischeMesse_02_Gloria.ly Pembaur_VierteLateinischeMesse_03_Credo.ly Pembaur_VierteLateinischeMesse_04_Sanctus.ly Pembaur_VierteLateinischeMesse_05_Benedictus.ly Pembaur_VierteLateinischeMesse_06_Agnus.ly Pembaur_VierteLateinischeMesse_Settings.ly
instruments = Fl ClI ClII CorI CorII TbeI TbeII Tim VI VII Va O VcB
vocal = S A T B
scores = OrganScore ChoralScore OrchestralScore LongScore
extensions = $(instruments) $(vocal) $(scores)
# Cl Wd Cor Tre Br V Str StrQ ChStrQ
TEX_TYPES = $(scores) Instruments
TEX_FILES = %(TEX_TYPES:%=Tex_Pembaur_VierteLateinischeMesse_%.tex)
TEX_OUTPUT = %(TEX_FILES:%.tex=%.pdf)
pdfs = %(extensions:%=Pembaur_VierteLateinischeMesse_%.pdf) $(TEX_OUTPUT)
.PHONY: all clean
all: $(extensions)
instruments: $(instruments)
vocal: $(vocal)
scores: $(scores)
tex: $(TEX_OUTPUT)
full: $(extensions)
clean:
for i in $(extensions); do \
rm -f Pembaur_VierteLateinischeMesse_$${i}.pdf Pembaur_VierteLateinischeMesse_$${i}.ps; \
done; \
rm -f Pembaur_VierteLateinischeMesse.ps Pembaur_VierteLateinischeMesse.pdf; \
for i in $(TEX_TYPES); do \
rm -f Tex_Pembaur_VierteLateinischeMesse_$${i}.{aux,log,out,pdf,toc,}; \
done
$(extensions): % : Pembaur_VierteLateinischeMesse_%.pdf $(SRCS)
Pembaur_VierteLateinischeMesse_%.pdf : Pembaur_VierteLateinischeMesse_%.ly
lilypond $<
Tex_%.pdf: Tex_%.tex %.pdf
latex $<
_______________________________________________
lilypond-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/lilypond-devel