summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAngel Pons <th3fanbus@gmail.com>2020-07-27 20:28:27 +0200
committerPatrick Georgi <pgeorgi@google.com>2020-07-29 09:27:33 +0000
commit9a5dd7accf5c7504852746ec63cfc07dcb22e456 (patch)
tree6965b4c8167668533c2476ca9e952b904701f442
parent2a28c816140ca9f5d53e5d550101d189ccd5829d (diff)
downloadcoreboot-9a5dd7accf5c7504852746ec63cfc07dcb22e456.tar.xz
lib/libgcov.c: Do not redefine `alloca`
This is already defined in <commonlib/helpers.h> and it gets included implicitly by some other header. Fixes building with code coverage. Change-Id: Id2dc6cc34b6f1d351d8e1b52d8cc4ada8666c673 Signed-off-by: Angel Pons <th3fanbus@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/43974 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
-rw-r--r--src/lib/libgcov.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/libgcov.c b/src/lib/libgcov.c
index 887351aa57..571aa7bb8e 100644
--- a/src/lib/libgcov.c
+++ b/src/lib/libgcov.c
@@ -25,12 +25,12 @@ permissions described in the GCC Runtime Library Exception, version
#ifdef __COREBOOT__
#include <stdlib.h>
#include <string.h>
+#include <commonlib/helpers.h>
#include <console/console.h>
#include <assert.h>
typedef s32 pid_t;
#define gcc_assert(x) ASSERT(x)
#define fprintf(file, x...) printk(BIOS_ERR, x)
-#define alloca(size) __builtin_alloca(size)
#include "gcov-glue.c"
/* Define MACROs to be used by coreboot compilation. */