PageRenderTime 22ms CodeModel.GetById 14ms app.highlight 4ms RepoModel.GetById 1ms app.codeStats 1ms

/Makefile

http://github.com/petar/GoHTTP
Makefile | 70 lines | 42 code | 18 blank | 10 comment | 5 complexity | 2b5b1169a016cf4d91aff8cd8bcacf40 MD5 | raw file
 1# Copyright 2009 The Go Authors. All rights reserved.
 2# Use of this source code is governed by a BSD-style
 3# license that can be found in the LICENSE file.
 4#
 5# After editing the DIRS= list or adding imports to any Go files
 6# in any of those directories, run:
 7#
 8#	./deps.bash
 9#
10# to rebuild the dependency information in Make.deps.
11
12nullstring :=
13space := $(nullstring) # a space at the end
14ifndef GOBIN
15QUOTED_HOME=$(subst $(space),\ ,$(HOME))
16GOBIN=$(QUOTED_HOME)/bin
17endif
18QUOTED_GOBIN=$(subst $(space),\ ,$(GOBIN))
19
20all: install
21
22DIRS=\
23     	util\
24	http\
25	cache\
26	server\
27	server/static\
28	server/rpc\
29
30TEST=\
31	$(filter-out $(NOTEST),$(DIRS))
32
33BENCH=\
34	$(filter-out $(NOBENCH),$(TEST))
35
36clean.dirs: $(addsuffix .clean, $(DIRS))
37install.dirs: $(addsuffix .install, $(DIRS))
38nuke.dirs: $(addsuffix .nuke, $(DIRS))
39test.dirs: $(addsuffix .test, $(TEST))
40bench.dirs: $(addsuffix .bench, $(BENCH))
41
42%.clean:
43	+cd $* && $(QUOTED_GOBIN)/gomake clean
44
45%.install:
46	+cd $* && $(QUOTED_GOBIN)/gomake install
47
48%.nuke:
49	+cd $* && $(QUOTED_GOBIN)/gomake nuke
50
51%.test:
52	+cd $* && $(QUOTED_GOBIN)/gomake test
53
54%.bench:
55	+cd $* && $(QUOTED_GOBIN)/gomake bench
56
57clean: clean.dirs
58
59install: install.dirs
60
61test:	test.dirs
62
63bench:	bench.dirs
64
65nuke: nuke.dirs
66
67deps:
68	./deps.bash
69
70-include Make.deps