From fad5c590b6730f52994574fa0b613dc328d31085 Mon Sep 17 00:00:00 2001 From: Ryan Stecker Date: Thu, 24 Jul 2014 15:35:44 -0500 Subject: [PATCH] Fix not adding the "include" directory to the spcomp search path. --- sourcepawn/compiler/sc1.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/sourcepawn/compiler/sc1.c b/sourcepawn/compiler/sc1.c index 1389ace3..09058200 100644 --- a/sourcepawn/compiler/sc1.c +++ b/sourcepawn/compiler/sc1.c @@ -1212,11 +1212,14 @@ static void setconfig(char *root) #else if (root!=NULL) strlcpy(path,root,sizeof path); /* path + filename (hopefully) */ +#endif + # if defined __MSDOS__ /* strip the options (appended to the path + filename) */ if ((ptr=strpbrk(path," \t/"))!=NULL) *ptr='\0'; -# endif +# endif /* __MSDOS__ */ + /* terminate just behind last \ or : */ if ((ptr=strrchr(path,DIRSEP_CHAR))!=NULL || (ptr=strchr(path,':'))!=NULL) { /* If there is no "\" or ":", the string probably does not contain the @@ -1246,19 +1249,20 @@ static void setconfig(char *root) } /* if */ } /* if */ insert_path(path); + /* same for the codepage root */ # if !defined NO_CODEPAGE *ptr='\0'; if (!cp_path(path,"codepage")) error(169,path); /* codepage path */ -# endif +# endif /* !NO_CODEPAGE */ + /* also copy the root path (for the XML documentation) */ # if !defined SC_LIGHT *ptr='\0'; strcpy(sc_rootpath,path); -# endif +# endif /* !SC_LIGHT */ } /* if */ -#endif /* macintosh */ } static void setcaption(void)