From 222848283aa13e2e378223a5514f596c76abac58 Mon Sep 17 00:00:00 2001 From: rekado Date: Fri, 3 Jun 2016 09:06:32 +0200 Subject: Use multiple CPU cores for lilypond. --- targets.mk | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'targets.mk') diff --git a/targets.mk b/targets.mk index a25d070..17cdc6b 100644 --- a/targets.mk +++ b/targets.mk @@ -1,7 +1,12 @@ +# What soundfont to use to generate the MIDI file SOUNDFONT = $(HOME)/soundfonts/FluidR3GM.sf2 +# Determine how many processors are present +CPU_CORES=`grep -m1 "cpu cores" /proc/cpuinfo | tr -cd '[:digit:]'` +# The command to run lilypond +LILY_CMD = lilypond -ddelete-intermediate-files -djob-count=$(CPU_CORES) %.midi: %.ly parts/*.ly - lilypond $< + $(LILY_CMD) $< %.wav: %.midi fluidsynth -r 48000 -F $@ -l -R no -i -n -a alsa $(SOUNDFONT) $< -- cgit v1.2.3