Skip to content

Commit

Permalink
zephyr: Change main function to return an int.
Browse files Browse the repository at this point in the history
Zephyr v3.4.0 changed the declaration of the main function to return an
int to allow building Zephyr without the -ffreestanding compiler flag.

Signed-off-by: Maureen Helm <[email protected]>
  • Loading branch information
MaureenHelm authored and dpgeorge committed Oct 1, 2024
1 parent 90c5b04 commit a7ae3a3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ports/zephyr/src/zephyr_start.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,13 @@
int real_main(void);
int mp_console_init(void);

void main(void) {
int main(void) {
#ifdef CONFIG_CONSOLE_SUBSYS
mp_console_init();
#else
zephyr_getchar_init();
#endif
real_main();

return 0;
}

0 comments on commit a7ae3a3

Please sign in to comment.