From 6e84dafcc72d1cd6d028b42f1801e092a91d3214 Mon Sep 17 00:00:00 2001 From: Tobias Burnus Date: Wed, 6 Dec 2023 08:57:29 +0100 Subject: [PATCH] tsystem.h: Declare calloc/realloc #ifdef inhibit_libc Declare calloc and realloc #ifndef and inhibit_libc is defined. Those are used by libgcc/emutls.c. gcc/ChangeLog: * tsystem.h (calloc, realloc): Declare when inhibit_libc. --- gcc/tsystem.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gcc/tsystem.h b/gcc/tsystem.h index 081c73345cdb..c49ff578cb79 100644 --- a/gcc/tsystem.h +++ b/gcc/tsystem.h @@ -50,6 +50,14 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see extern void *malloc (size_t); #endif +#ifndef calloc +extern void *calloc(size_t, size_t); +#endif + +#ifndef realloc +extern void *realloc(void *, size_t); +#endif + #ifndef free extern void free (void *); #endif -- 2.47.2