forked from aressky/TSF4G
-
Notifications
You must be signed in to change notification settings - Fork 0
/
search.mk
34 lines (22 loc) · 804 Bytes
/
search.mk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#parameter list
SUBMODS ?=
#parameter list
CLEANTARGET = clean
INSTALLTARGET = install
TAGSTARGET = tags
SUBMODSCLEAN = $(patsubst %, %.$(CLEANTARGET), $(SUBMODS))
SUBMODSINSTALL = $(patsubst %, %.$(INSTALLTARGET), $(SUBMODS))
SUBMODSTAGS = $(patsubst %, %.$(TAGSTARGET), $(SUBMODS))
.PHONY: all $(CLEANTARGET) $(INSTALLTARGET) $(TAGSTARGET) $(SUBMODS)
all: $(SUBMODS)
$(CLEANTARGET): $(SUBMODSCLEAN)
$(INSTALLTARGET): $(SUBMODSINSTALL)
$(TAGSTARGET): $(SUBMODSTAGS)
$(SUBMODS):
cd $@ && $(MAKE);
$(SUBMODSTAGS):
cd $(patsubst %.$(TAGSTARGET),%, $@) && $(MAKE) $(TAGSTARGET);
$(SUBMODSCLEAN):
cd $(patsubst %.$(CLEANTARGET),%, $@) && $(MAKE) $(CLEANTARGET);
$(SUBMODSINSTALL):
cd $(patsubst %.$(INSTALLTARGET),%, $@) && $(MAKE) $(INSTALLTARGET);