From d606f227983d8fb76e1cc754ca52d0d00036e911 Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Sat, 28 Sep 2013 21:31:01 -0700 Subject: [PATCH] Makefile: Put the class flags after the generic flags. The class flags are more specific than the generic CFLAGS flags and should be after them so that they have a chance to override them. The class specific flags weren't really used on anything but ARM so this should be a fairly safe change even in the x86 Makefiles. BUG=None TEST=Built for link. Built and booted on nyan. BRANCH=None Change-Id: I7a949efbb1d2841f9f0d28433772092d9f95db36 Signed-off-by: Gabe Black Reviewed-on: https://chromium-review.googlesource.com/171016 Reviewed-by: Ronald Minnich Commit-Queue: Gabe Black Tested-by: Gabe Black --- Makefile | 2 +- Makefile.inc | 2 +- src/arch/armv7/Makefile.inc | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 9aafe7cd6c..e2be68bfd0 100644 --- a/Makefile +++ b/Makefile @@ -260,7 +260,7 @@ ifn$(EMPTY)def $(1)-objs_$(2)_template de$(EMPTY)fine $(1)-objs_$(2)_template $(obj)/$$(1).$(1).o: src/$$(1).$(2) $(obj)/config.h $(4) @printf " CC $$$$(subst $$$$(obj)/,,$$$$(@))\n" - $(CC) $(3) -MMD $$$$(CFLAGS) -c -o $$$$@ $$$$< + $(CC) -MMD $$$$(CFLAGS) $(3) -c -o $$$$@ $$$$< en$(EMPTY)def end$(EMPTY)if endef diff --git a/Makefile.inc b/Makefile.inc index 1a732f9eec..7e0b44c5ca 100644 --- a/Makefile.inc +++ b/Makefile.inc @@ -305,7 +305,7 @@ $(obj)/%.romstage.o $(abspath $(obj))/%.romstage.o: $(obj)/%.c $(obj)/config.h $ $(obj)/%.bootblock.o $(abspath $(obj))/%.bootblock.o: $(obj)/%.c $(obj)/config.h $(OPTION_TABLE_H) @printf " CC $(subst $(obj)/,,$(@))\n" - $(CC) -MMD $(bootblock-c-ccopts) $(CFLAGS) -c -o $@ $< + $(CC) -MMD $(CFLAGS) $(bootblock-c-ccopts) -c -o $@ $< ####################################################################### # Clean up rules diff --git a/src/arch/armv7/Makefile.inc b/src/arch/armv7/Makefile.inc index 82c35643a7..23c3eba553 100644 --- a/src/arch/armv7/Makefile.inc +++ b/src/arch/armv7/Makefile.inc @@ -265,7 +265,7 @@ $(objgenerated)/bootblock.inc: $(src)/arch/armv7/$(subst ",,$(CONFIG_BOOTBLOCK_S $(CC) $(bootblock-c-ccopts) $(INCLUDES) -MM \ -MT$(objgenerated)/bootblock.inc \ $< > $(objgenerated)/bootblock.inc.d - $(CC) $(bootblock-c-ccopts) -c -S $(CFLAGS) -I. $(INCLUDES) $< -o $@ + $(CC) -c -S $(CFLAGS) $(bootblock-c-ccopts) -I. $(INCLUDES) $< -o $@ $(objcbfs)/bootblock.debug: $(objgenerated)/bootblock.o $(objgenerated)/bootblock.ld $$(bootblock-objs) $(stages) $(obj)/config.h @printf " LINK $(subst $(obj)/,,$(@))\n"