ia64/xen-unstable

view tools/xcs/Makefile @ 4958:cc1c80ec8139

bitkeeper revision 1.1432 (428a0372Dg_Q9mIOPOkDIc7D3T4aww)

Merge firebug.cl.cam.ac.uk:/auto/groups/xeno-xenod/BK/xen-unstable.bk
into firebug.cl.cam.ac.uk:/local/scratch/cl349/xen-unstable.bk
author cl349@firebug.cl.cam.ac.uk
date Tue May 17 14:45:06 2005 +0000 (2005-05-17)
parents a01199a95070 c7fbd1dc68a0
children 3615dfd94bdb 9f22db685802
line source
1 # Makefile for XCS
2 # Andrew Warfield, 2004
4 XEN_ROOT=../..
5 include $(XEN_ROOT)/tools/Rules.mk
7 XCS_INSTALL_DIR = /usr/sbin
9 INSTALL = install
10 INSTALL_PROG = $(INSTALL) -m0755
11 INSTALL_DIR = $(INSTALL) -d -m0755
13 CC = gcc
14 CFLAGS = -Wall -Werror -g3 -D _XOPEN_SOURCE=600
16 CFLAGS += -I $(XEN_XC)
17 CFLAGS += -I $(XEN_LIBXC)
18 CFLAGS += -I $(XEN_LIBXUTIL)
20 SRCS :=
21 SRCS += ctrl_interface.c
22 SRCS += bindings.c
23 SRCS += connection.c
24 SRCS += evtchn.c
25 SRCS += xcs.c
27 HDRS = $(wildcard *.h)
28 OBJS = $(patsubst %.c,%.o,$(SRCS))
29 BIN = xcs
31 all: $(BIN) xcsdump
33 clean:
34 $(RM) *.a *.so *.o *.rpm $(BIN) xcsdump
36 xcsdump: xcsdump.c dump.c
37 $(CC) $(CFLAGS) -o xcsdump xcsdump.c -L$(XEN_LIBXC) -L$(XEN_LIBXUTIL) \
38 ctrl_interface.c evtchn.c dump.c -lxc -lxutil
40 $(BIN): $(OBJS)
41 $(CC) $(CFLAGS) $^ -o $@ -L$(XEN_LIBXC) -L$(XEN_LIBXUTIL) -lxc -lxutil
43 $(OBJS): $(HDRS)
45 install: xcs xcsdump
46 $(INSTALL_DIR) -p $(DESTDIR)/$(XCS_INSTALL_DIR)
47 $(INSTALL_DIR) -p $(DESTDIR)/usr/include
48 $(INSTALL_PROG) xcs $(DESTDIR)/$(XCS_INSTALL_DIR)
49 $(INSTALL_PROG) xcsdump $(DESTDIR)/$(XCS_INSTALL_DIR)
50 $(INSTALL_PROG) xcs_proto.h $(DESTDIR)/usr/include