Page 1 of 1

Compiler sees syntax errors in sgdk header files?

Posted: Mon Dec 15, 2014 1:22 am
by BroOfTheSun
Hi, so I'm using SGDK to mess around with creating a game. When I compile my program, I get errors with SGDK header files such as:

Code: Select all

...
c:/sgdk/inc/memory.h:155 error: syntax error before "MEM_getFree"
...
It's referring to this line:

Code: Select all

...
u16  MEM_getFree();
u16 is defined in the types.h file, but that's not included in the memory.h file. I'm sure I'm not understanding the issue here. Does anyone know what's going on?

Posted: Mon Dec 15, 2014 11:05 am
by Stef
When you use SGDK, just include "genesis.h", nothing else ! So you will have access to full SGDK API ;)