xen-vtx-unstable

view tools/examples/Makefile @ 6774:4d899a738d59

merge?
author cl349@firebug.cl.cam.ac.uk
date Tue Sep 13 15:05:49 2005 +0000 (2005-09-13)
parents adb70d525dbd cac138ea9284
children e7c7196fa329 8ca0f98ba8e2
line source
1 XEN_ROOT = ../../
2 include $(XEN_ROOT)/tools/Rules.mk
4 INSTALL = install
5 INSTALL_DIR = $(INSTALL) -d -m0755
6 INSTALL_PROG = $(INSTALL) -m0755
7 INSTALL_DATA = $(INSTALL) -m0644
9 # Init scripts.
10 XEND_INITD = init.d/xend
11 XENDOMAINS_INITD = init.d/xendomains
13 # Xen configuration dir and configs to go there.
14 XEN_CONFIG_DIR = /etc/xen
15 XEN_CONFIGS = xend-config.sxp
16 XEN_CONFIGS += xmexample1
17 XEN_CONFIGS += xmexample2
18 XEN_CONFIGS += xmexample.vmx
20 # Xen script dir and scripts to go there.
21 XEN_SCRIPT_DIR = /etc/xen/scripts
22 XEN_SCRIPTS = network-bridge vif-bridge
23 XEN_SCRIPTS += network-route vif-route
24 XEN_SCRIPTS += block-phy
25 XEN_SCRIPTS += block-file
26 XEN_SCRIPTS += block-enbd
28 XEN_BOOT_DIR = /usr/$(LIBDIR)/xen/boot
29 XEN_BOOT = mem-map.sxp
31 XEN_HOTPLUG_DIR = /etc/hotplug
32 XEN_HOTPLUG_SCRIPTS = xen-backend.agent
34 all:
35 build:
37 install: all install-initd install-configs install-scripts install-boot \
38 install-hotplug
40 xmexample.vmx: xmexample.vmx.in
41 sed -e 's/@@LIBDIR@@/$(LIBDIR)/' < $< > $@
43 install-initd:
44 [ -d $(DESTDIR)/etc/init.d ] || $(INSTALL_DIR) $(DESTDIR)/etc/init.d
45 $(INSTALL_PROG) $(XEND_INITD) $(DESTDIR)/etc/init.d
46 $(INSTALL_PROG) $(XENDOMAINS_INITD) $(DESTDIR)/etc/init.d
48 install-configs: $(XEN_CONFIGS)
49 [ -d $(DESTDIR)$(XEN_CONFIG_DIR) ] || \
50 $(INSTALL_DIR) $(DESTDIR)$(XEN_CONFIG_DIR)
51 [ -d $(DESTDIR)$(XEN_CONFIG_DIR)/auto ] || \
52 $(INSTALL_DIR) $(DESTDIR)$(XEN_CONFIG_DIR)/auto
53 for i in $(XEN_CONFIGS); \
54 do [ -a $(DESTDIR)$(XEN_CONFIG_DIR)/$$i ] || \
55 $(INSTALL_DATA) $$i $(DESTDIR)$(XEN_CONFIG_DIR); \
56 done
58 install-scripts:
59 [ -d $(DESTDIR)$(XEN_SCRIPT_DIR) ] || \
60 $(INSTALL_DIR) $(DESTDIR)$(XEN_SCRIPT_DIR)
61 for i in $(XEN_SCRIPTS); \
62 do [ -a $(DESTDIR)$(XEN_SCRIPT_DIR)/$$i ] || \
63 $(INSTALL_PROG) $$i $(DESTDIR)$(XEN_SCRIPT_DIR); \
64 done
66 install-boot:
67 [ -d $(DESTDIR)$(XEN_BOOT_DIR) ] || \
68 $(INSTALL_DIR) $(DESTDIR)$(XEN_BOOT_DIR)
69 for i in $(XEN_BOOT); \
70 do [ -a $(DESTDIR)$(XEN_BOOT_DIR)/$$i ] || \
71 $(INSTALL_PROG) $$i $(DESTDIR)$(XEN_BOOT_DIR); \
72 done
74 install-hotplug:
75 [ -d $(DESTDIR)$(XEN_HOTPLUG_DIR) ] || \
76 $(INSTALL_DIR) $(DESTDIR)$(XEN_HOTPLUG_DIR)
77 for i in $(XEN_HOTPLUG_SCRIPTS); \
78 do \
79 $(INSTALL_PROG) $$i $(DESTDIR)$(XEN_HOTPLUG_DIR); \
80 done
82 clean:
83 $(RM) xmexample.vmx