debuggers.hg
view xen/arch/x86/Makefile @ 19966:3f12d48f2880
x86: merge final linking scripts
While unrelated to the previous four patches, I realized that the two
scripts are nearly identical when coding those earlier patches, and
this patch depends on them in order to apply cleanly.
As an extra measure, it also adjusts the (unused) space freed at the
end of the per-CPU area to include all alignment space needed before
the first actual constituent of the .bss section (up to 7 pages on
x86-64).
Signed-off-by: Jan Beulich <jbeulich@novell.com>
While unrelated to the previous four patches, I realized that the two
scripts are nearly identical when coding those earlier patches, and
this patch depends on them in order to apply cleanly.
As an extra measure, it also adjusts the (unused) space freed at the
end of the per-CPU area to include all alignment space needed before
the first actual constituent of the .bss section (up to 7 pages on
x86-64).
Signed-off-by: Jan Beulich <jbeulich@novell.com>
author | Keir Fraser <keir.fraser@citrix.com> |
---|---|
date | Mon Jul 13 11:51:07 2009 +0100 (2009-07-13) |
parents | aca402831ac1 |
children | a3ae60f8b546 |
line source
1 subdir-y += acpi
2 subdir-y += cpu
3 subdir-y += genapic
4 subdir-y += hvm
5 subdir-y += mm
6 subdir-y += oprofile
8 subdir-$(x86_32) += x86_32
9 subdir-$(x86_64) += x86_64
11 obj-y += apic.o
12 obj-y += bitops.o
13 obj-y += clear_page.o
14 obj-y += copy_page.o
15 obj-y += compat.o
16 obj-y += delay.o
17 obj-y += dmi_scan.o
18 obj-y += domctl.o
19 obj-y += domain.o
20 obj-y += domain_build.o
21 obj-y += e820.o
22 obj-y += extable.o
23 obj-y += flushtlb.o
24 obj-y += platform_hypercall.o
25 obj-y += i387.o
26 obj-y += i8259.o
27 obj-y += io_apic.o
28 obj-y += msi.o
29 obj-y += ioport_emulate.o
30 obj-y += irq.o
31 obj-y += microcode.o
32 obj-y += microcode_amd.o
33 obj-y += microcode_intel.o
34 obj-y += mm.o
35 obj-y += mpparse.o
36 obj-y += nmi.o
37 obj-y += numa.o
38 obj-y += pci.o
39 obj-y += physdev.o
40 obj-y += setup.o
41 obj-y += shutdown.o
42 obj-y += smp.o
43 obj-y += smpboot.o
44 obj-y += srat.o
45 obj-y += string.o
46 obj-y += sysctl.o
47 obj-y += time.o
48 obj-y += trace.o
49 obj-y += traps.o
50 obj-y += usercopy.o
51 obj-y += x86_emulate.o
52 obj-y += machine_kexec.o
53 obj-y += crash.o
54 obj-y += tboot.o
55 obj-y += hpet.o
56 obj-y += bzimage.o
58 obj-$(crash_debug) += gdbstub.o
60 x86_emulate.o: x86_emulate/x86_emulate.c x86_emulate/x86_emulate.h
62 $(TARGET): $(TARGET)-syms boot/mkelf32
63 ./boot/mkelf32 $(TARGET)-syms $(TARGET) 0x100000 \
64 `$(NM) -nr $(TARGET)-syms | head -n 1 | sed -e 's/^\([^ ]*\).*/0x\1/'`
66 ALL_OBJS := $(BASEDIR)/arch/x86/boot/built_in.o $(ALL_OBJS)
68 $(TARGET)-syms: $(ALL_OBJS) xen.lds
69 $(MAKE) -f $(BASEDIR)/Rules.mk $(BASEDIR)/common/symbols-dummy.o
70 $(LD) $(LDFLAGS) -T xen.lds -N $(ALL_OBJS) \
71 $(BASEDIR)/common/symbols-dummy.o -o $(@D)/.$(@F).0
72 $(NM) -n $(@D)/.$(@F).0 | $(BASEDIR)/tools/symbols >$(@D)/.$(@F).0.S
73 $(MAKE) -f $(BASEDIR)/Rules.mk $(@D)/.$(@F).0.o
74 $(LD) $(LDFLAGS) -T xen.lds -N $(ALL_OBJS) \
75 $(@D)/.$(@F).0.o -o $(@D)/.$(@F).1
76 $(NM) -n $(@D)/.$(@F).1 | $(BASEDIR)/tools/symbols >$(@D)/.$(@F).1.S
77 $(MAKE) -f $(BASEDIR)/Rules.mk $(@D)/.$(@F).1.o
78 $(LD) $(LDFLAGS) -T xen.lds -N $(ALL_OBJS) \
79 $(@D)/.$(@F).1.o -o $@
80 rm -f $(@D)/.$(@F).[0-9]*
82 asm-offsets.s: $(TARGET_SUBARCH)/asm-offsets.c
83 $(CC) $(CFLAGS) -S -o $@ $<
85 xen.lds: xen.lds.S
86 $(CC) -P -E -Ui386 $(AFLAGS) -o $@ $<
88 boot/mkelf32: boot/mkelf32.c
89 $(HOSTCC) $(HOSTCFLAGS) -o $@ $<
91 .PHONY: clean
92 clean::
93 rm -f asm-offsets.s xen.lds boot/*.o boot/*~ boot/core boot/mkelf32
94 rm -f $(BASEDIR)/.xen-syms.[0-9]* boot/.*.d
95 rm -f boot/reloc.S boot/reloc.lnk boot/reloc.bin