-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
70 lines (51 loc) · 1.36 KB
/
Makefile
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
# Copyright 2010 GoDCCP Authors. All rights reserved.
# Use of this source code is governed by a
# license that can be found in the LICENSE file.
# Copyright 2009 The Go Authors. All rights reserved.
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
#
# After editing the DIRS= list or adding imports to any Go files
# in any of those directories, run:
#
# ./deps.bash
#
# to rebuild the dependency information in Make.deps.
nullstring :=
space := $(nullstring) # a space at the end
ifndef GOBIN
QUOTED_HOME=$(subst $(space),\ ,$(HOME))
GOBIN=$(QUOTED_HOME)/bin
endif
QUOTED_GOBIN=$(subst $(space),\ ,$(GOBIN))
all: install
DIRS=\
utp\
TEST=\
$(filter-out $(NOTEST),$(DIRS))
BENCH=\
$(filter-out $(NOBENCH),$(TEST))
clean.dirs: $(addsuffix .clean, $(DIRS))
install.dirs: $(addsuffix .install, $(DIRS))
nuke.dirs: $(addsuffix .nuke, $(DIRS))
test.dirs: $(addsuffix .test, $(TEST))
bench.dirs: $(addsuffix .bench, $(BENCH))
%.clean:
+cd $* && $(QUOTED_GOBIN)/gomake clean
%.install:
+cd libutp && make
+cd $* && $(QUOTED_GOBIN)/gomake install
%.nuke:
+cd $* && $(QUOTED_GOBIN)/gomake nuke
%.test:
+cd $* && $(QUOTED_GOBIN)/gomake test
%.bench:
+cd $* && $(QUOTED_GOBIN)/gomake bench
clean: clean.dirs
install: install.dirs
test: test.dirs
bench: bench.dirs
nuke: nuke.dirs
deps:
./deps.bash
-include Make.deps