From 2ea25552e9a78a01d522384be4193292527b017f Mon Sep 17 00:00:00 2001 From: Paul Menzel Date: Tue, 13 Oct 2015 17:30:57 +0200 Subject: bootblock: Link timestamp.c only with EARLY_CBMEM_INIT MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Commit dbeedbef (arch/x86/bootblock: Link in object files selected with bootblock-y) breaks building of x86 boards with `CONFIG_EARLY_CBMEM_INIT` *not* selected but CBMEM time stamp collection enabled. Aaron Durbin explained as below [1] and provided this patch to fix it. > That change actually processes bootblock-objs where before it never did > such a thing. I'm sure this isn’t the only issue lurking. bootblock on > x86 implied romcc and thus all the bootblock-y += rules that other > architectures use worked, but now all the implied assumptions are no > longer true on x86. > > timestamp stuff on x86 !CONFIG_EARLY_CBMEM_INIT is the issue you're > seeing. In order to compile timestamp.c for bootblock under these > conditions will mean there needs to be some more Makefile guarding. [1] http://review.coreboot.org/11864 Change-Id: I3441b9fcdbbc8bbe82b9f2075e60668a846ecf09 Fix-by: Aaron Durbin Signed-off-by: Paul Menzel Reviewed-on: http://review.coreboot.org/11875 Reviewed-by: Aaron Durbin Reviewed-by: Alexandru Gagniuc Tested-by: build bot (Jenkins) --- src/lib/Makefile.inc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/lib/Makefile.inc b/src/lib/Makefile.inc index f9a23c523506..b98623aa0132 100644 --- a/src/lib/Makefile.inc +++ b/src/lib/Makefile.inc @@ -28,7 +28,10 @@ bootblock-$(CONFIG_GENERIC_GPIO_LIB) += gpio.c bootblock-y += libgcc.c bootblock-$(CONFIG_GENERIC_UDELAY) += timer.c +ifeq ($(CONFIG_EARLY_CBMEM_INIT),y) bootblock-$(CONFIG_COLLECT_TIMESTAMPS) += timestamp.c +endif + bootblock-$(CONFIG_CONSOLE_CBMEM) += cbmem_console.c bootblock-$(CONFIG_I2C_TPM) += delay.c bootblock-y += memchr.c -- cgit v1.2.3