aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>2006-03-30 14:31:57 +0100
committerkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>2006-03-30 14:31:57 +0100
commit4734f491063e6b2d43e273a178da06e93a92080d (patch)
treeff0640c60cc84eed6192fdd622ceacc4a5817680
parent31903a3370b4c056d7d97ee3b495bd48677d4ab9 (diff)
downloadxen-4734f491063e6b2d43e273a178da06e93a92080d.tar.gz
xen-4734f491063e6b2d43e273a178da06e93a92080d.tar.bz2
xen-4734f491063e6b2d43e273a178da06e93a92080d.zip
Use AFLAGS for assembly files so we can "+=" more flags.
From: Jimi Xenidis <jimix@watson.ibm.com> Signed-off-by: Keir Fraser <keir@xensource.com>
-rw-r--r--xen/Rules.mk5
-rw-r--r--xen/arch/ia64/Makefile2
-rw-r--r--xen/arch/x86/Makefile2
3 files changed, 6 insertions, 3 deletions
diff --git a/xen/Rules.mk b/xen/Rules.mk
index f887ea44f5..ade8b87a1e 100644
--- a/xen/Rules.mk
+++ b/xen/Rules.mk
@@ -55,11 +55,14 @@ ifneq ($(max_phys_cpus),)
CFLAGS-y += -DMAX_PHYS_CPUS=$(max_phys_cpus)
endif
+AFLAGS-y += -D__ASSEMBLY__
+
ALL_OBJS := $(ALL_OBJS-y)
CFLAGS := $(strip $(CFLAGS) $(CFLAGS-y))
+AFLAGS := $(strip $(AFLAGS) $(AFLAGS-y))
%.o: %.c $(HDRS) Makefile
$(CC) $(CFLAGS) -c $< -o $@
%.o: %.S $(HDRS) Makefile
- $(CC) $(CFLAGS) -D__ASSEMBLY__ -c $< -o $@
+ $(CC) $(CFLAGS) $(AFLAGS) -c $< -o $@
diff --git a/xen/arch/ia64/Makefile b/xen/arch/ia64/Makefile
index 444f4eb30b..381c6d739b 100644
--- a/xen/arch/ia64/Makefile
+++ b/xen/arch/ia64/Makefile
@@ -76,7 +76,7 @@ $(BASEDIR)/include/asm-ia64/.offsets.h.stamp:
# I'm sure a Makefile wizard would know a better way to do this
xen.lds.s: xen/xen.lds.S
- $(CC) -E $(CPPFLAGS) -P -DXEN -D__ASSEMBLY__ \
+ $(CC) -E $(CPPFLAGS) -P -DXEN $(AFLAGS) \
-o xen.lds.s xen/xen.lds.S
clean:: FORCE
diff --git a/xen/arch/x86/Makefile b/xen/arch/x86/Makefile
index 3fa20dd7d0..c7a2e6ae1d 100644
--- a/xen/arch/x86/Makefile
+++ b/xen/arch/x86/Makefile
@@ -72,7 +72,7 @@ asm-offsets.s: $(TARGET_SUBARCH)/asm-offsets.c $(HDRS)
$(CC) $(CFLAGS) -S -o $@ $<
xen.lds: $(TARGET_SUBARCH)/xen.lds.S $(HDRS)
- $(CC) $(CFLAGS) -P -E -Ui386 -D__ASSEMBLY__ -o $@ $<
+ $(CC) $(CFLAGS) -P -E -Ui386 $(AFLAGS) -o $@ $<
boot/mkelf32: boot/mkelf32.c
$(HOSTCC) $(HOSTCFLAGS) -o $@ $<