]> rtime.felk.cvut.cz Git - jailhouse-test.git/blob - build/l4/Makefile
jailhouse: Improve benchmark and add cmdline parameter passing into launch script.
[jailhouse-test.git] / build / l4 / Makefile
1 all: fiasco l4re
2
3 help:
4         @echo "Supported targets:"
5         @echo "  all           - Build all"
6         @echo "  fiasco        - Build Fiasco kernel"
7         @echo "  fiasco-config - Reconfigure Fiasco kernel"
8         @echo "  l4re          - Build L4 runtime environment"
9         @echo "  l4re-config   - Reconfigure L4 runtime environment"
10         @echo "  hello         - Build image with hello entry for jailhouse"
11         @echo "  benchmarks    - (Re)Build ferret directory & prepare image with ferret scalar demo"
12         @echo "  bench         - (Re)Build benchmark directory & prepare image with benchmark for jailhouse"
13         @echo "  bench-bare    - (Re)Build benchmark directory & prepare image with benchmark for bare hardware launch"
14
15 .NOTPARALLEL:
16
17 ########## Fiasco ##########
18
19 .PHONY: fiasco
20 fiasco: fiasco/globalconfig.out
21         $(MAKE) -C fiasco
22
23 .PHONY: fiasco-config
24 fiasco-config: fiasco/globalconfig.out
25
26 ifeq ($(MAKECMDGOALS),fiasco-config)
27 .PHONY: fiasco/globalconfig.out
28 endif
29
30 fiasco/globalconfig.out: fiasco/.stamp-jh
31         $(MAKE) -C $(@D) config
32         touch $@
33
34 fiasco/.stamp-jh:
35         $(MAKE) -C ../../l4/kernel/fiasco BUILDDIR=$(CURDIR)/$(@D)
36         touch $@
37
38 ########## L4Re ##########
39
40 L4RE_PKGS = acpica bootstrap cxx_thread drivers drivers-frst fb-drv     \
41 hello input io/io io/libio io/libio-direct io/libio-io io/libvbus       \
42 l4re-core/crtn l4re-core/cxx l4re-core/cxx_libc_io l4re-core/l4re       \
43 l4re-core/l4re_c l4re-core/l4re_kernel l4re-core/l4re_vfs               \
44 l4re-core/l4sys l4re-core/l4util l4re-core/ldscripts l4re-core/ldso     \
45 l4re-core/libc_backends l4re-core/libgcc l4re-core/libgcc-pure          \
46 l4re-core/libkproxy l4re-core/libloader l4re-core/libsigma0             \
47 l4re-core/libstdc++-headers l4re-core/libstdc++-v3                      \
48 l4re-core/libstdc++-v3-minimal l4re-core/libsupc++                      \
49 l4re-core/libsupc++-minimal l4re-core/lua l4re-core/moe l4re-core/ned   \
50 l4re-core/sigma0 l4re-core/uclibc l4re-core/uclibc-headers              \
51 l4re-core/uclibc-minimal libedid libirq libvcpu loader log lxfuxlibc    \
52 rtc shmcKE) -C l4re MODULE_SEARCH_PATH=$(CURDIR)/fiasco E=hello elfimage x86emu
53
54 .PHONY: l4re
55 l4re: l4re/.kconfig
56         $(MAKE) -C l4re #S="$(L4RE_PKGS:%=pkg/%)"
57
58 .PHONY: l4re-config
59 l4re-config: l4re/.kconfig
60
61 ifeq ($(MAKECMDGOALS),l4re-config)
62 .PHONY: l4re/.kconfig
63 endif
64
65 l4re/.kconfig: l4re/.stamp-jh
66         $(MAKE) -C $(@D) config
67         touch $@
68
69 l4re/.stamp-jh:
70         $(MAKE) -C ../../l4/l4 B=$(CURDIR)/$(@D)
71         touch $@
72
73 ########## Application ##########
74
75 .PHONY: hello
76 hello:
77         $(MAKE) -C l4re MODULE_SEARCH_PATH=$(CURDIR)/fiasco E=hello BOOTSTRAP_PKG=bootstrap_custom elfimage
78
79 .PHONY: benchmarks
80 benchmarks:
81         $(MAKE) -C l4re MODULE_SEARCH_PATH=$(CURDIR)/fiasco S=pkg/ferret:pkg/ferret/examples/monitors/simple_mon_re
82         $(MAKE) -C l4re MODULES_LIST=$(CURDIR)/ferret-modules.list MODULE_SEARCH_PATH=$(CURDIR)/fiasco:$(CURDIR)/ned-confs/ E=ferret-bench BOOTSTRAP_PKG=bootstrap_custom elfimage
83
84 .PHONY: bench
85 bench:
86         $(MAKE) -C l4re MODULE_SEARCH_PATH=$(CURDIR)/fiasco S=pkg/benchmark
87         $(MAKE) -C l4re MODULES_LIST=$(CURDIR)/ferret-modules.list MODULE_SEARCH_PATH=$(CURDIR)/fiasco:$(CURDIR)/ned-confs/ E=bench BOOTSTRAP_PKG=bootstrap_custom elfimage
88
89 .PHONY: bench-bare
90 bench-bare:
91         $(MAKE) -C l4re MODULE_SEARCH_PATH=$(CURDIR)/fiasco S=pkg/benchmark
92         $(MAKE) -C l4re MODULES_LIST=$(CURDIR)/ferret-modules.list MODULE_SEARCH_PATH=$(CURDIR)/fiasco:$(CURDIR)/ned-confs/ E=bench-bare BOOTSTRAP_PKG=bootstrap elfimage