From 79f9010e80a04f2e0fb0cca5759e3215dff79aff Mon Sep 17 00:00:00 2001 From: Patrick Georgi Date: Sun, 25 Nov 2012 14:31:08 +0100 Subject: [PATCH] build system: Add hook to postprocess classes (object lists) This will be used to minimize the ramstage class, to avoid command line lengths to exceed the limit on mingw, esp. after we got rid of ramstage.a Change-Id: I80582d04476545c275e8d1d08fb52a99f58cebcc Signed-off-by: Patrick Georgi Reviewed-on: http://review.coreboot.org/1910 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer --- Makefile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Makefile b/Makefile index 7df6be816c..4faf12baf9 100644 --- a/Makefile +++ b/Makefile @@ -237,6 +237,10 @@ $(foreach class,$(classes),$(eval $(class)-srcs:=$(sort $($(class)-srcs)))) src-to-obj=$(addsuffix .$(1).o, $(basename $(patsubst src/%, $(obj)/%, $($(1)-srcs)))) $(foreach class,$(classes),$(eval $(class)-objs:=$(call src-to-obj,$(class)))) +# Call post-processors if they're defined +$(foreach class,$(classes),\ + $(if $(value $(class)-postprocess),$(eval $(call $(class)-postprocess,$($(class)-objs))))) + allsrcs:=$(foreach var, $(addsuffix -srcs,$(classes)), $($(var))) allobjs:=$(foreach var, $(addsuffix -objs,$(classes)), $($(var))) alldirs:=$(sort $(abspath $(dir $(allobjs))))