Stephane-D / SGDK

SGDK - A free and open development kit for the Sega Mega Drive
https://www.patreon.com/SGDK
MIT License
1.7k stars 179 forks source link

Projects fail to build with C23 #301

Closed PatchMixolydic closed 7 months ago

PatchMixolydic commented 7 months ago

Trying to build a simple project with EXTRA_FLAGS=-std=c2x make -f $GDK/makefile.gen yields the following:

In file included from /home/patchmixolydic/mars/m68k-elf/inc/genesis.h:6,
                 from src/main.c:1:
/home/patchmixolydic/mars/m68k-elf/inc/types.h:113:12: error: two or more data types in declaration specifiers
  113 | typedef u8 bool;
      |            ^~~~
/home/patchmixolydic/mars/m68k-elf/inc/types.h:113:1: warning: useless type name in empty declaration
  113 | typedef u8 bool;
      | ^~~~~~~
make: *** [/home/patchmixolydic/mars/m68k-elf/makefile.gen:171: out/src/main.o] Error 1

This may be related to N2934, which introduced a bool keyword/predefined macro.

Stephane-D commented 7 months ago

Thanks for reporting, should be fixed !