ia64/xen-unstable

view xen/Rules.mk @ 2570:30a9b33481dc

bitkeeper revision 1.1159.90.2 (415be9d5hTw1zLV9fA-AYcekmwhMwg)

Discard devices early for local migrate.
author mjw@wray-m-3.hpl.hp.com
date Thu Sep 30 11:11:17 2004 +0000 (2004-09-30)
parents d9439135569e
children 7765521a561d 1b906236acc9
line source
2 verbose ?= n
3 debug ?= n
4 debugger ?= n
5 perfc ?= n
6 trace ?= n
8 # Currently supported architectures:
9 # {COMPILE,TARGET}_ARCH := x86
10 # {COMPILE,TARGET}_SUBARCH := x86_32 | x86_64
11 COMPILE_ARCH := x86
12 COMPILE_SUBARCH := $(shell uname -m | sed -e s/i.86/x86_32/)
14 TARGET_ARCH ?= $(COMPILE_ARCH)
15 TARGET_SUBARCH ?= $(COMPILE_SUBARCH)
17 TARGET := $(BASEDIR)/xen
18 HDRS := $(wildcard $(BASEDIR)/include/xen/*.h)
19 HDRS += $(wildcard $(BASEDIR)/include/scsi/*.h)
20 HDRS += $(wildcard $(BASEDIR)/include/hypervisor-ifs/*.h)
21 HDRS += $(wildcard $(BASEDIR)/include/asm-$(TARGET_ARCH)/*.h)
22 # compile.h is always regenerated, but other files shouldn't be rebuilt
23 HDRS := $(subst $(BASEDIR)/include/xen/compile.h,,$(HDRS))
25 C_SRCS := $(wildcard *.c)
26 S_SRCS := $(wildcard *.S)
27 OBJS := $(patsubst %.S,%.o,$(S_SRCS))
28 OBJS += $(patsubst %.c,%.o,$(C_SRCS))
30 # Note that link order matters!
31 ALL_OBJS := $(BASEDIR)/common/common.o
32 ALL_OBJS += $(BASEDIR)/drivers/char/driver.o
33 ALL_OBJS += $(BASEDIR)/drivers/acpi/driver.o
34 ALL_OBJS += $(BASEDIR)/drivers/pci/driver.o
35 ALL_OBJS += $(BASEDIR)/arch/$(TARGET_ARCH)/arch.o
37 HOSTCC = gcc
38 HOSTCFLAGS = -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer
40 include $(BASEDIR)/arch/$(TARGET_ARCH)/Rules.mk
42 ifneq ($(debug),y)
43 CFLAGS += -DNDEBUG
44 ifeq ($(verbose),y)
45 CFLAGS += -DVERBOSE
46 endif
47 else
48 CFLAGS += -DVERBOSE
49 endif
51 ifeq ($(debugger),y)
52 CFLAGS += -DXEN_DEBUGGER
53 endif
55 ifeq ($(perfc),y)
56 CFLAGS += -DPERF_COUNTERS
57 endif
59 ifeq ($(trace),y)
60 CFLAGS += -DTRACE_BUFFER
61 endif
63 %.o: %.c $(HDRS) Makefile
64 $(CC) $(CFLAGS) -c $< -o $@
66 %.o: %.S $(HDRS) Makefile
67 $(CC) $(CFLAGS) -D__ASSEMBLY__ -c $< -o $@