1 --------------------------------------------------------------------------
2 -- Copyright (c) 2007-2010, ETH Zurich.
3 -- All rights reserved.
5 -- This file is distributed under the terms in the attached LICENSE file.
6 -- If you do not find this file, copies can be found by writing to:
7 -- ETH Zurich D-INFK, Haldeneggsteig 4, CH-8092 Zurich. Attn: Systems Group.
9 -- Hakefile for /usr/monitor
11 --------------------------------------------------------------------------
14 arch_dir = "arch" </> archFamily arch
16 arch_dirs "x86_32" = [ arch_dir, "arch/x86" ]
17 arch_dirs "x86_64" = [ arch_dir, "arch/x86" ]
18 arch_dirs "k1om" = [ arch_dir, "arch/x86" ]
19 arch_dirs _ = [ arch_dir ]
21 common_srcs = [ "trace_support.c", "bfscope_support.c", "ram_alloc.c", "inter.c", "spawn.c", "invocations.c", "iref.c",
22 "main.c", "monitor_server.c", "monitor_rpc_server.c",
23 "boot.c", "queue.c", "domain.c", "intermon_bindings.c",
24 "resource_ctrl.c", "timing.c", "send_cap.c", "octopus_client.c",
25 "capops/capsend.c", "capops/capqueue.c", "capops/internal.c",
26 "capops/caplock.c", "capops/copy.c", "capops/move.c",
27 "capops/retrieve.c", "capops/delete.c", "capops/revoke.c",
28 "capops/retype.c", "capops/init.c", "capops/deletestep.c" ]
30 arch_srcs "x86_32" = [ "arch/x86/boot.c", "arch/x86/inter.c", "arch/x86/monitor_server.c", "arch/x86/notify_ipi.c" ]
31 arch_srcs "x86_64" = [ "arch/x86/boot.c", "arch/x86/inter.c", "arch/x86/monitor_server.c", "arch/x86/notify_ipi.c" ]
32 arch_srcs "k1om" = [ "arch/x86/boot.c", "arch/x86/inter.c", "arch/x86/monitor_server.c", "arch/x86/notify_ipi.c" ]
33 arch_srcs "armv7" = [ "arch/armv7/boot.c", "arch/armv7/inter.c", "arch/armv7/monitor_server.c", "arch/armv7/notify_ipi.c" ]
34 arch_srcs "armv8" = [ "arch/armv8/boot.c", "arch/armv8/inter.c", "arch/armv8/monitor_server.c", "arch/armv8/notify_ipi.c" ]
37 idc_srcs = concat $ map getsrcs $ optInterconnectDrivers $ options arch
39 getsrcs "ump" = [ "ump_support.c" ]
40 getsrcs "multihop" = [ "multihop_support.c" ]
43 idc_libraries = concat $ map getsrcs $ optInterconnectDrivers $ options arch
45 getsrcs "multihop" = [ "collections" ]
49 build application { target = "monitor",
50 architectures = [arch],
51 cFiles = common_srcs ++ arch_srcs arch ++ idc_srcs,
52 flounderDefs = [ "mem", "monitor", "monitor_blocking" ],
53 flounderBindings = [ "monitor_mem", "intermon" ],
54 flounderExtraBindings = [ ("monitor", ["loopback"]),
55 ("monitor_mem", ["rpcclient"]),
56 ("mem", ["rpcclient"]),
57 ("octopus", ["rpcclient"]) ],
58 addLinkFlags = [ "-e _start_init" ],
59 addIncludes = "include" : [ "include" </> a | a <- arch_dirs arch ],
61 [ "spawndomain", "bench", "trace", "elf", "cap_predicates" ]
64 ) | arch <- allArchitectures ]