ide/Compiler Configs: Fix to replace COMPILER_SUFFIX and DEBUG_SUFFIX in IDE
authorJerome St-Louis <jerome@ecere.com>
Wed, 18 Apr 2012 04:46:17 +0000 (00:46 -0400)
committerJerome St-Louis <jerome@ecere.com>
Wed, 18 Apr 2012 04:46:17 +0000 (00:46 -0400)
ide/src/IDESettings.ec
ide/src/project/ProjectConfig.ec

index 27010f9..47c84e5 100644 (file)
@@ -69,8 +69,8 @@ PathRelationship eString_PathRelated(char * path, char * to, char * pathDiff)
 
 char * CopyValidateMakefilePath(char * path)
 {
-   const int map[]  =    { 0,           1,           2,             3,             4,           0,            1,                  7         };
-   const char * vars[] = { "$(MODULE)", "$(CONFIG)", "$(PLATFORM)", "$(COMPILER)", "$(TARGET)", "$(PROJECT)", "$(CONFIGURATION)", (char *)0 };
+   const int map[]  =    { 0,           1,           2,             3,             4,           5,                    6,                 0,             1,                 7         };
+   const char * vars[] = { "$(MODULE)", "$(CONFIG)", "$(PLATFORM)", "$(COMPILER)", "$(TARGET)", "$(COMPILER_SUFFIX)", "$(DEBUG_SUFFIX)", "$(PROJECT)",  "$(CONFIGURATION)",(char *)0 };
 
    char * copy = null;
    if(path)
index 6b33bd4..e558307 100644 (file)
@@ -111,6 +111,25 @@ class DirExpression : struct
                            d += strlen(compilerName);
                            c = i;
                         }
+                        else if(!strnicmp(&expr[c + 2], "Debug_Suffix", n))
+                        {
+                           // We don't support .debug from the IDE yet...
+                           c = i;
+                        }
+                        else if(!strnicmp(&expr[c + 2], "Compiler_Suffix", n))
+                        {
+                           if(compilerName[0] && strcmpi(compilerName, "default"))
+                           {
+                              buffer[d] = '.';
+                              buffer[d+1] = '\0';
+                              strcat(buffer, compilerName);
+                              CamelCase(&buffer[d]);
+                              d += strlen(compilerName)+1;
+                              c = i;
+                           }
+                           else
+                              c = i;
+                        }
                         else
                         {
                            buffer[d++] = expr[c];