From a5f30ee27b6a515907fbbb45ab1f24fbefc00544 Mon Sep 17 00:00:00 2001 From: Danny Milosavljevic Date: Sun, 15 Nov 2020 23:00:25 +0100 Subject: [PATCH] ARM: Special-case setjmp struct for gcc with mes libc. * include/setjmp.h (__jmp_buf): Special-case setjmp struct for gcc with mes libc. --- include/setjmp.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/include/setjmp.h b/include/setjmp.h index a283cd61..2f79eeb1 100644 --- a/include/setjmp.h +++ b/include/setjmp.h @@ -27,12 +27,22 @@ #else // ! SYSTEM_LIBC #if __arm__ +#if __GNUC__ +#warning "It is not supported to use mes' setjmp implementation together with GCC. Continuing with best-effort implementation." +typedef struct +{ + long __sp; + long __lr; + long __registers[8]; /* Note: Keep in sync with lib/arm-mes-gcc/setjmp.c */ +} __jmp_buf; +#else typedef struct { long __fp; long __lr; long __sp; } __jmp_buf; +#endif #else typedef struct {