Compiler sees syntax errors in sgdk header files?

SGDK only sub forum

Moderator: Stef

Post Reply
BroOfTheSun
Interested
Posts: 33
Joined: Fri Dec 12, 2014 2:41 am
Location: USA - Chicago, IL

Compiler sees syntax errors in sgdk header files?

Post 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?
Stef
Very interested
Posts: 3131
Joined: Thu Nov 30, 2006 9:46 pm
Location: France - Sevres
Contact:

Post by Stef »

When you use SGDK, just include "genesis.h", nothing else ! So you will have access to full SGDK API ;)
Post Reply