RJP Computing wrote:
> #define DEBUG 2
^^^
The token DEBUG is defined here...
I am not sure what you are saying. The package files are not fed to the compiler so there is no reference that DEBUG was defined as 2.
Let me clearer.
toLua package file:
#define WHAT_EVER 3
Should generate:
tolua_constant(tolua_S,"WHAT_EVER",3);
But currently generates:
tolua_constant(tolua_S,"WHAT_EVER",WHAT_EVER);
So when you go to build the generated file the compiler complains that WHAT_EVER is undefined.
Another possible fix would be to copy the '#define' to the generated file as well as generate:
tolua_constant(tolua_S,"WHAT_EVER",WHAT_EVER);