On 10 Jan 2003 at 9:58, Frank Heckenbach wrote:
J. David Bryan wrote:
Notes from building gpc-20021128 with gcc-3.2.1 configured for i486-pc-mingw32:
- GPC will not run on Win9x/WinME systems, due to a Mingw-specific
change in gcc/config/i386/xm-mingw32.h. Patching gpc.c is required.
What exactly is the difference?
It is the age-old front slash problem. In gcc-2.95.3.x, xm-mingw32.h contained these entries:
/* Even though we support "/", allow "" since everybody tests both. */ #ifdef TARGET_W9x /* This kludge must go, once we can get '/' to work on W9x */ #define DIR_SEPARATOR_2 '/' #define DIR_SEPARATOR '\' #else #define DIR_SEPARATOR '/' #define DIR_SEPARATOR_2 '\' #endif
So, the suggestion I gave earlier would have worked if you added "-DTARGET_W9x" to the CFLAGS when compiling. However, with gcc-3.x, xm-mingw32.h only now contains this:
/* Even though we support "/", allow "" since everybody tests both. */ #define DIR_SEPARATOR '/' #define DIR_SEPARATOR_2 '\'
This means that "-DTARGET_W9x" will not work with gcc-3.x. However, removing the earlier entries seems to indicate that the Mingw guys consider that the Win9x problem has been solved. If this is not the case, then David Bryan might as well report the problem on the Mingw list.
A short term solution would be to reverse the entries in xm-mingw32.h - i.e., do this:
#define DIR_SEPARATOR '\' #define DIR_SEPARATOR_2 '/'
This should cure the problem without any patches to gpc.c. If you don't want anything other than GPC to be affected, then perhaps an appropriate IFDEF can be used - like they did in gcc-2.95.3.x as shown above.
Best regards, The Chief --------- Prof. Abimbola Olowofoyeku (The African Chief) Web: http://www.bigfoot.com/~african_chief/