From 5a32091c5cd1ef6ef4d8362415ca90d4339b4768 Mon Sep 17 00:00:00 2001 From: Romain Goffe Date: Sat, 15 Oct 2011 05:12:11 +0200 Subject: [PATCH] makefile: support books/ dir --- makefile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/makefile b/makefile index 564f74ea..82bc19b2 100644 --- a/makefile +++ b/makefile @@ -15,8 +15,9 @@ # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # -SONGBOOKS := $(wildcard books/*.sb) -TARGETS = $(SONGBOOKS:%.sb=%) +BOOKS_DIR=books/ +SONGBOOKS := $(wildcard $(BOOKS_DIR)/*.sb) +TARGETS = $(SONGBOOKS:$(BOOKS_DIR)/%.sb=%) PDF = $(TARGETS:%=%.pdf) @@ -58,7 +59,7 @@ clean: @rm -f $(TARGETS:%=%.d) $(TARGETS:%=%.tex) $(TARGETS:%=%.aux) \ $(TARGETS:%=%.toc) $(TARGETS:%=%.out) $(TARGETS:%=%.log) \ $(TARGETS:%=%.nav) $(TARGETS:%=%.snm) - @rm -f *.sbx *.sxd + @rm -f *.sbx *.sxd *.sxc @rm -f lilypond/*.ps @rm -f *.pyc @@ -79,10 +80,10 @@ $(PDF): %.pdf: %.tex %.aux %.sbx: %.sxd $(MAKE_INDEX) $< > $@ -%.tex: books/%.sb +%.tex: $(BOOKS_DIR)/%.sb $(MAKE_SONGBOOK) -s $< -o $@ -%.d: books/%.sb +%.d: $(BOOKS_DIR)/%.sb $(MAKE_SONGBOOK) -s $< -d -o $@ %.pdf: %.ly