Skip to contentSkip to conversation

Fix Xen target image dependencies.

Xen-changelog Hollis Blanchard 2 participants 2 messages Mar 21, 2006 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw
Quoted 30 lines · Xen patchbot -unstable

# HG changeset patch
# User [email protected]
# Node ID 0d9855e12426ff764a7b58fba70438b6ef986388 # Parent a27f22868d68fbea055dfdd496d8c1dbc6be999c Fix Xen target image dependencies.

diff -r a27f22868d68 -r 0d9855e12426 xen/Makefile

xen/Makefile +2 -0
@@ -55,12 +55,14 @@
 	[ -e include/asm ] || ln -sf asm-$(TARGET_ARCH) include/asm
 	$(MAKE) -C arch/$(TARGET_ARCH) asm-offsets.s
 	$(MAKE) include/asm-$(TARGET_ARCH)/asm-offsets.h
+ifneq ($(TARGET_ARCH),x86)
 	$(MAKE) -C common
 	$(MAKE) -C drivers
 ifeq ($(ACM_SECURITY),y)
 	$(MAKE) -C acm
 endif
 	$(MAKE) -C arch/$(TARGET_ARCH)
+endif
 	$(MAKE) -C arch/$(TARGET_ARCH) $(TARGET)
 
 # drivers/char/console.o contains static banner/compile info. Blow it away.

diff -r a27f22868d68 -r 0d9855e12426 xen/arch/x86/Makefile

xen/arch/x86/Makefile line 61

Quoted 8 lines
xen/arch/x86/Makefile +1 -1
@@ -55,7 +55,7 @@
 	./boot/mkelf32 $(TARGET)-syms $(TARGET) 0x100000 \
 	`$(NM) $(TARGET)-syms | sort | tail -n 1 | sed -e 's/^\([^ ]*\).*/0x\1/'`
 
-$(TARGET)-syms: boot/$(TARGET_SUBARCH).o xen.lds
+$(TARGET)-syms: boot/$(TARGET_SUBARCH).o $(ALL_OBJS) xen.lds
 	$(LD) $(LDFLAGS) -T xen.lds -N \
 	    boot/$(TARGET_SUBARCH).o $(ALL_OBJS) -o $@
 	$(NM) -n $@ | $(BASEDIR)/tools/symbols >$(BASEDIR)/xen-syms.S

This one's looking a bit sketchy to me.

Of course the PPC Makefile has the same target with the ALL_OBJS dependencies, and Alex's patch for ia64 is the same. Since the built_in.o dependencies are forced into their respective directories, we build e.g. xen/common and then re-enter it while building xen/arch/$(TARGET_ARCH). In the changeset above, you just hacked around it for x86 (I assume because you were going to sleep and didn't want to leave the build in a funny state :) .

This patch works more generally.

Signature · 28 lines
Hollis Blanchard
IBM Linux Technology Center



Since we now have general rules to build ALL_OBJS, we don't need to manually 
build them. Compile-tested on x86 and PPC.

Signed-off-by: Hollis Blanchard <[email protected]>

diff -r b9486f0d6970 xen/Makefile
--- a/xen/Makefile      Mon Mar 20 18:38:50 2006 +0100
+++ b/xen/Makefile      Mon Mar 20 19:58:17 2006 -0600
@@ -55,14 +55,6 @@ clean: delete-unfresh-files
        [ -e include/asm ] || ln -sf asm-$(TARGET_ARCH) include/asm
        $(MAKE) -C arch/$(TARGET_ARCH) asm-offsets.s
        $(MAKE) include/asm-$(TARGET_ARCH)/asm-offsets.h
-ifneq ($(TARGET_ARCH),x86)
-       $(MAKE) -C common
-       $(MAKE) -C drivers
-ifeq ($(ACM_SECURITY),y)
-       $(MAKE) -C acm
-endif
-       $(MAKE) -C arch/$(TARGET_ARCH)
-endif
        $(MAKE) -C arch/$(TARGET_ARCH) $(TARGET)

 # drivers/char/console.o contains static banner/compile info. Blow it away.
#2 lore raw
Quoted 6 lines · Hollis Blanchard

Of course the PPC Makefile has the same target with the ALL_OBJS dependencies, and Alex's patch for ia64 is the same. Since the built_in.o dependencies are forced into their respective directories, we build e.g. xen/common and then re-enter it while building xen/arch/$(TARGET_ARCH). In the changeset above, you just hacked around it for x86 (I assume because you were going to sleep and didn't want to leave the build in a funny state :) .

Yeah, I was under the illusion I could avoid breaking the ia64 build. :-)

-- Keir