forked from mirage/mirage-skeleton
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
63 lines (53 loc) · 1.26 KB
/
Copy pathMakefile
File metadata and controls
63 lines (53 loc) · 1.26 KB
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
-include Makefile.config
BASE_TESTS = \
tutorial/noop \
tutorial/noop-functor \
tutorial/hello \
tutorial/hello-key \
tutorial/lwt/echo_server \
tutorial/lwt/heads1 \
tutorial/lwt/heads2 \
tutorial/lwt/timeout1 \
tutorial/lwt/timeout2 \
tutorial/lwt/echo_server \
tutorial/app_info \
device-usage/clock \
device-usage/conduit_server \
device-usage/console \
device-usage/http-fetch \
device-usage/kv_ro \
device-usage/network \
device-usage/ping6 \
device-usage/prng \
applications/dhcp \
applications/dns \
applications/static_website_tls
ifeq ($(MODE),muen)
TESTS = $(BASE_TESTS)
else
TESTS = $(BASE_TESTS)
TESTS += device-usage/block
endif
ifdef WITH_TRACING
TESTS += device-usage/tracing
endif
CONFIGS = $(patsubst %, %-configure, $(TESTS))
BUILDS = $(patsubst %, %-build, $(TESTS))
TESTRUN = $(patsubst %, %-testrun, $(TESTS))
CLEANS = $(patsubst %, %-clean, $(TESTS))
all: build
configure: $(CONFIGS)
build: $(BUILDS)
testrun: $(TESTRUN)
clean: $(CLEANS)
## default tests
%-configure:
cd $* && $(MIRAGE) configure -t $(MODE) $(MIRAGE_FLAGS)
%-build: %-configure
-cp Makefile.user $*
cd $* && $(MAKE) depend && $(MAKE)
%-clean:
-cd $* && $(MAKE) clean
-$(RM) $*/Makefile.user
%-testrun:
$(SUDO) sh ./testrun.sh $*