#define OPTION_NOREGPARMS "-noregparms"
static const char *_preCmd[] = {
- "sdcpp", "-version", "-Wall", "-lang-c++", "-DSDCC=1",
+ "sdcpp", "-Wall", "-lang-c++", "-DSDCC=1",
"-I" SDCC_INCLUDE_DIR, "$l", "$1", "$2", NULL
};
static int preProcess (char **envp)
{
char *argv[128];
+ char procDef[128];
preOutName = NULL;
else
_addToList(preArgv, "-DSDCC_MODEL_SMALL");
+ /* add port (processor information to processor */
+ sprintf(procDef,"-DSDCC_%s",port->target);
+ _addToList(preArgv,procDef);
+
if (!preProcOnly)
preOutName = strdup(tmpnam(NULL));
( SPEC_SCLS(sym->etype) != S_AUTO &&
SPEC_SCLS(sym->etype) != S_FIXED &&
SPEC_SCLS(sym->etype) != S_REGISTER &&
+ SPEC_SCLS(sym->etype) != S_STACK &&
+ SPEC_SCLS(sym->etype) != S_XSTACK &&
SPEC_SCLS(sym->etype) != S_CONSTANT )) {
werror(E_AUTO_ASSUMED,sym->name) ;
/* the storage class to reflect where the var will go */
if ( sym->level && SPEC_SCLS(sym->etype) == S_FIXED) {
if ( options.stackAuto || (currFunc && IS_RENT(currFunc->etype)))
- SPEC_SCLS(sym->etype) = (options.model ?
+ SPEC_SCLS(sym->etype) = (options.useXstack ?
S_XSTACK : S_STACK ) ;
else
- SPEC_SCLS(sym->etype) = (options.model ?
+ SPEC_SCLS(sym->etype) = (options.useXstack ?
S_XDATA :S_DATA ) ;
}
}