summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Georgi <patrick@georgi-clan.de>2012-11-25 14:31:08 +0100
committerPatrick Georgi <patrick@georgi-clan.de>2012-11-27 22:01:56 +0100
commit79f9010e80a04f2e0fb0cca5759e3215dff79aff (patch)
tree8af4ef8a7287109d86e07d8e5c91d9d41de9ae95
parent6999217ab6e4c8ed4c7f19a5578c36b01ad883ed (diff)
downloadcoreboot-79f9010e80a04f2e0fb0cca5759e3215dff79aff.tar.xz
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 <patrick@georgi-clan.de> Reviewed-on: http://review.coreboot.org/1910 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
-rw-r--r--Makefile4
1 files changed, 4 insertions, 0 deletions
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))))