diff --git a/include/zephyr/types.h b/include/zephyr/types.h index 80e80d4de74..7e5e87b2ce3 100644 --- a/include/zephyr/types.h +++ b/include/zephyr/types.h @@ -29,6 +29,11 @@ typedef union { void (*thepfunc)(void); } z_max_align_t; +#ifdef __cplusplus +/* Zephyr requires an int main(void) signature with C linkage for the application main if present */ +extern int main(void); +#endif + #ifdef __cplusplus } #endif