ia64/xen-unstable

view tools/examples/Makefile @ 6766:219d96d545fc

merge?
author cl349@firebug.cl.cam.ac.uk
date Mon Sep 12 20:00:41 2005 +0000 (2005-09-12)
parents e9d01c5dc7b4 cac138ea9284
children adb70d525dbd 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/lib/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 install-initd:
41 [ -d $(DESTDIR)/etc/init.d ] || $(INSTALL_DIR) $(DESTDIR)/etc/init.d
42 $(INSTALL_PROG) $(XEND_INITD) $(DESTDIR)/etc/init.d
43 $(INSTALL_PROG) $(XENDOMAINS_INITD) $(DESTDIR)/etc/init.d
45 install-configs:
46 [ -d $(DESTDIR)$(XEN_CONFIG_DIR) ] || \
47 $(INSTALL_DIR) $(DESTDIR)$(XEN_CONFIG_DIR)
48 [ -d $(DESTDIR)$(XEN_CONFIG_DIR)/auto ] || \
49 $(INSTALL_DIR) $(DESTDIR)$(XEN_CONFIG_DIR)/auto
50 for i in $(XEN_CONFIGS); \
51 do [ -a $(DESTDIR)$(XEN_CONFIG_DIR)/$$i ] || \
52 $(INSTALL_DATA) $$i $(DESTDIR)$(XEN_CONFIG_DIR); \
53 done
55 install-scripts:
56 [ -d $(DESTDIR)$(XEN_SCRIPT_DIR) ] || \
57 $(INSTALL_DIR) $(DESTDIR)$(XEN_SCRIPT_DIR)
58 for i in $(XEN_SCRIPTS); \
59 do [ -a $(DESTDIR)$(XEN_SCRIPT_DIR)/$$i ] || \
60 $(INSTALL_PROG) $$i $(DESTDIR)$(XEN_SCRIPT_DIR); \
61 done
63 install-boot:
64 [ -d $(DESTDIR)$(XEN_BOOT_DIR) ] || \
65 $(INSTALL_DIR) $(DESTDIR)$(XEN_BOOT_DIR)
66 for i in $(XEN_BOOT); \
67 do [ -a $(DESTDIR)$(XEN_BOOT_DIR)/$$i ] || \
68 $(INSTALL_PROG) $$i $(DESTDIR)$(XEN_BOOT_DIR); \
69 done
71 install-hotplug:
72 [ -d $(DESTDIR)$(XEN_HOTPLUG_DIR) ] || \
73 $(INSTALL_DIR) $(DESTDIR)$(XEN_HOTPLUG_DIR)
74 for i in $(XEN_HOTPLUG_SCRIPTS); \
75 do \
76 $(INSTALL_PROG) $$i $(DESTDIR)$(XEN_HOTPLUG_DIR); \
77 done
79 clean: