4 # Magic: find and include LilyPond's StepMake rules
7 # 1: follow LILYPONDPREFIX
8 # 2: try source tree in home
9 # 3: try installed tree in $HOME
10 # 4: try system installed tree
11 # 5: try system installed tree
13 make-root=$(wildcard $(depth)/make)
15 make-root?=$(wildcard $(LILYPONDPREFIX)/make)
16 make-root?=$(wildcard $(HOME)/usr/share/lilypond/make)
17 make-root?=$(wildcard /usr/share/lilypond/make)
18 make-root?=$(wildcard /usr/local/share/lilypond/make)
19 # make-root=<LilyPond's datadir>/make
22 SUBDIRS = $(filter-out .,$(shell find . -maxdepth 1 -type d -not -name 'out*'))
26 LOCALSTEPMAKE_TEMPLATES=ports mutopia ly
27 include $(make-root)/stepmake.make
29 $(error can't find LilyPond's stepmake installation)