summaryrefslogtreecommitdiff
path: root/Makefile.subdir
blob: f7f0e0cd07618f2befd1d4ab0c4b15189c9850f0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
subdirs: $(SUBDIRS)
$(SUBDIRS):
	@flock $@ $(MAKE) -C $@

all: $(subdirs)

SUBDIRS_CLEAN = $(addsuffix .clean,$(SUBDIRS))
clean: $(SUBDIRS_CLEAN)
$(SUBDIRS_CLEAN): %.clean:
	@flock $* $(MAKE) -C $* clean

SUBDIRS_INSTALL = $(addsuffix .install,$(SUBDIRS))
install: $(SUBDIRS_INSTALL)
$(SUBDIRS_INSTALL): %.install:
	@flock $* $(MAKE) -C $* install

.PHONY: all clean install $(SUBDIRS)