ia64/xen-unstable

view tools/xcs/Makefile @ 6422:e24fd7012ffb

merge?
author cl349@firebug.cl.cam.ac.uk
date Thu Aug 25 10:09:39 2005 +0000 (2005-08-25)
parents 2f20c2fce2c5 6e899a3840b2
children 4abd299ef2f6
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)
19 SRCS :=
20 SRCS += ctrl_interface.c
21 SRCS += bindings.c
22 SRCS += connection.c
23 SRCS += evtchn.c
24 SRCS += xcs.c
26 HDRS = $(wildcard *.h)
27 OBJS = $(patsubst %.c,%.o,$(SRCS))
28 BIN = xcs
30 all: $(BIN) xcsdump
32 clean:
33 $(RM) *.a *.so *.o *.rpm $(BIN) xcsdump
35 xcsdump: xcsdump.c dump.c
36 $(CC) $(CFLAGS) -o xcsdump xcsdump.c -L$(XEN_LIBXC) \
37 ctrl_interface.c evtchn.c dump.c -lxenctrl
39 $(BIN): $(OBJS)
40 $(CC) $(CFLAGS) $^ -o $@ -L$(XEN_LIBXC) -lxenctrl
42 $(OBJS): $(HDRS)
44 install: xcs xcsdump
45 $(INSTALL_DIR) -p $(DESTDIR)/$(XCS_INSTALL_DIR)
46 $(INSTALL_DIR) -p $(DESTDIR)/usr/include
47 $(INSTALL_PROG) xcs $(DESTDIR)/$(XCS_INSTALL_DIR)
48 $(INSTALL_PROG) xcsdump $(DESTDIR)/$(XCS_INSTALL_DIR)
49 $(INSTALL_PROG) xcs_proto.h $(DESTDIR)/usr/include