From 49c296b3248f6c63ba1980029a0e16f0c5e43485 Mon Sep 17 00:00:00 2001 From: Karel Gardas Date: Fri, 21 Jul 2023 17:36:03 +0200 Subject: bsps/arm: fix nested extern decl. warnings brought by CMSIS files update --- bsps/arm/include/cmsis_gcc.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/bsps/arm/include/cmsis_gcc.h b/bsps/arm/include/cmsis_gcc.h index 4f0762d6dc..f8267ded0d 100644 --- a/bsps/arm/include/cmsis_gcc.h +++ b/bsps/arm/include/cmsis_gcc.h @@ -1,3 +1,6 @@ +/* + * The file was modified by RTEMS contributors. + */ /**************************************************************************//** * @file cmsis_gcc.h * @brief CMSIS compiler GCC header file @@ -136,6 +139,10 @@ */ __STATIC_FORCEINLINE __NO_RETURN void __cmsis_start(void) { +#ifdef __rtems__ +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wnested-externs" +#endif /* __rtems__ */ extern void _start(void) __NO_RETURN; typedef struct __copy_table { @@ -154,6 +161,10 @@ __STATIC_FORCEINLINE __NO_RETURN void __cmsis_start(void) extern const __zero_table_t __zero_table_start__; extern const __zero_table_t __zero_table_end__; +#ifdef __rtems__ +#pragma GCC diagnostic pop +#endif /* __rtems__ */ + for (__copy_table_t const* pTable = &__copy_table_start__; pTable < &__copy_table_end__; ++pTable) { for(uint32_t i=0u; iwlen; ++i) { pTable->dest[i] = pTable->src[i]; -- cgit v1.2.3