gcc 3.4.6 don't understand "#if PATHCMP==stricmp" where "#define PATHCMP stricmp"
Unified · Split
| @@ -101,6 +101,7 @@ · 100 unmodified lines | ||
| 101 | 101 | # define IS_DIRSEP(c) (c == '/' || c == '\\') |
| 102 | 102 | # define IS_ABSPATH(p) (IS_DIRSEP(p[0]) || (p[0] && p[1] == ':' && IS_DIRSEP(p[2]))) |
| 103 | 103 | # define PATHCMP stricmp |
| 104 | +# define PATH_NOCASE | |
| 104 | 105 | #else |
| 105 | 106 | # define IS_DIRSEP(c) (c == '/') |
| 106 | 107 | # define IS_ABSPATH(p) IS_DIRSEP(p[0]) |
| @@ -1480,7 +1480,7 @@ static void pragma_parse(TCCState *s1) · 1479 unmodified lines | ||
| 1480 | 1480 | char buf1[sizeof(file->filename) + sizeof(ONCE_PREFIX)]; |
| 1481 | 1481 | strcpy(buf1, ONCE_PREFIX); |
| 1482 | 1482 | strcat(buf1, file->filename); |
| 1483 | −#if PATHCMP==stricmp | |
| 1483 | +#ifdef PATH_NOCASE | |
| 1484 | 1484 | strupr(buf1); |
| 1485 | 1485 | #endif |
| 1486 | 1486 | add_cached_include(s1, file->filename, tok_alloc(buf1, strlen(buf1))->tok); |