ia64/xen-unstable

view xen/arch/ia64/Makefile @ 12423:2b0596c8a031

[IA64] create minimal vlapic.h

This fixes the ia64 build for xen-unstable.hg cset 12368:fda15861731e

Signed-off-by: Alex Williamson <alex.williamson@hp.com>
author awilliam@xenbuild.aw
date Mon Nov 13 10:56:08 2006 -0700 (2006-11-13)
parents 34452b288046
children d54bcabd0624
line source
1 subdir-y += xen
2 subdir-y += vmx
3 subdir-y += linux
4 subdir-y += linux-xen
6 $(TARGET)-syms: linux-xen/head.o $(ALL_OBJS) xen.lds.s
7 $(MAKE) -f $(BASEDIR)/Rules.mk $(BASEDIR)/common/symbols-dummy.o
8 $(LD) $(LDFLAGS) -T xen.lds.s -N \
9 -Map map.out linux-xen/head.o $(ALL_OBJS) \
10 $(BASEDIR)/common/symbols-dummy.o -o $@
11 $(NM) -n $@ | $(BASEDIR)/tools/symbols > $(BASEDIR)/xen-syms.S
12 $(MAKE) -f $(BASEDIR)/Rules.mk $(BASEDIR)/xen-syms.o
13 $(LD) $(LDFLAGS) -T xen.lds.s -N \
14 -Map map.out linux-xen/head.o $(ALL_OBJS) \
15 $(BASEDIR)/xen-syms.o -o $@
16 $(NM) -n $@ | $(BASEDIR)/tools/symbols >$(BASEDIR)/xen-syms.S
17 $(MAKE) -f $(BASEDIR)/Rules.mk $(BASEDIR)/xen-syms.o
18 $(LD) $(LDFLAGS) -T xen.lds.s -N \
19 -Map map.out linux-xen/head.o $(ALL_OBJS) \
20 $(BASEDIR)/xen-syms.o -o $@
21 rm -f $(BASEDIR)/xen-syms.S $(BASEDIR)/xen-syms.o
23 $(TARGET): $(TARGET)-syms
24 $(OBJCOPY) -R .note -R .comment -S $(TARGET)-syms $@
25 $(NM) -n $(TARGET)-syms | \
26 grep -v '\( [aUw] \)\|\(__crc_\)\|\( \$[adt]\)' \
27 > $(BASEDIR)/System.map
29 # Headers do not depend on auto-generated header, but object files do.
30 HDRS := $(subst $(BASEDIR)/include/asm-ia64/asm-xsi-offsets.h,,$(HDRS))
31 $(ALL_OBJS): $(BASEDIR)/include/asm-ia64/asm-xsi-offsets.h
33 asm-offsets.s: asm-offsets.c $(BASEDIR)/include/asm-ia64/.offsets.h.stamp
34 $(CC) $(CFLAGS) -DGENERATE_ASM_OFFSETS -DIA64_TASK_SIZE=0 -S -o $@ $<
36 asm-xsi-offsets.s: asm-xsi-offsets.c $(HDRS)
37 $(CC) $(CFLAGS) -S -o $@ $<
39 $(BASEDIR)/include/asm-ia64/asm-xsi-offsets.h: asm-xsi-offsets.s
40 @(set -e; \
41 echo "/*"; \
42 echo " * DO NOT MODIFY."; \
43 echo " *"; \
44 echo " * This file was auto-generated from $<"; \
45 echo " *"; \
46 echo " */"; \
47 echo ""; \
48 echo "#ifndef __ASM_XSI_OFFSETS_H__"; \
49 echo "#define __ASM_XSI_OFFSETS_H__"; \
50 echo ""; \
51 sed -ne "/^->/{s:^->\([^ ]*\) [\$$#]*\([^ ]*\) \(.*\):#define \1 \2 /* \3 */:; s:->::; p;}"; \
52 echo ""; \
53 echo "#endif") <$< >$@
55 $(BASEDIR)/include/asm-ia64/.offsets.h.stamp:
56 # Need such symbol link to make linux headers available
57 [ -e $(BASEDIR)/include/linux ] \
58 || ln -sf $(BASEDIR)/include/xen $(BASEDIR)/include/linux
59 [ -e $(BASEDIR)/include/asm-ia64/xen ] \
60 || ln -sf $(BASEDIR)/include/asm-ia64/linux $(BASEDIR)/include/asm-ia64/xen
61 # Link to HVM files in Xen for ia64/vti
62 [ -e $(BASEDIR)/include/asm-ia64/hvm/support.h ] \
63 || ln -sf ../../../include/asm-x86/hvm/support.h $(BASEDIR)/include/asm-ia64/hvm/support.h
64 [ -e $(BASEDIR)/include/asm-ia64/hvm/io.h ] \
65 || ln -sf ../../../include/asm-x86/hvm/io.h $(BASEDIR)/include/asm-ia64/hvm/io.h
66 [ -e $(BASEDIR)/include/asm-ia64/hvm/vpic.h ] \
67 || ln -sf ../../../include/asm-x86/hvm/vpic.h $(BASEDIR)/include/asm-ia64/hvm/vpic.h
68 [ -e $(BASEDIR)/include/asm-ia64/hvm/vioapic.h ] \
69 || ln -sf ../../../include/asm-x86/hvm/vioapic.h $(BASEDIR)/include/asm-ia64/hvm/vioapic.h
70 [ -e $(BASEDIR)/arch/ia64/vmx/hvm_vioapic.c ] \
71 || ln -sf ../../../arch/x86/hvm/vioapic.c $(BASEDIR)/arch/ia64/vmx/hvm_vioapic.c
73 # I'm sure a Makefile wizard would know a better way to do this
74 xen.lds.s: xen/xen.lds.S
75 $(CC) -E $(CPPFLAGS) -P -DXEN $(AFLAGS) \
76 -o xen.lds.s xen/xen.lds.S
78 .PHONY: clean
79 clean::
80 rm -f *.o *~ core xen.lds.s $(BASEDIR)/include/asm-ia64/.offsets.h.stamp asm-offsets.s map.out
81 rm -f asm-xsi-offsets.s $(BASEDIR)/include/asm-ia64/asm-xsi-offsets.h
82 rm -f $(BASEDIR)/System.map
83 rm -f vmx/hvm_*.c
84 rm -f $(BASEDIR)/include/asm-ia64/hvm/support.h
85 rm -f $(BASEDIR)/include/asm-ia64/hvm/io.h
86 rm -f $(BASEDIR)/include/asm-ia64/hvm/vpic.h
87 rm -f $(BASEDIR)/include/asm-ia64/hvm/vioapic.h