Prof A Olowofoyeku wrote:
- Compiled without problem for Mingw (gcc-3.3.3). However, the IFDEF
bug is still there under gcc-3.3.3 (e.g., the compiler completely ignores {$IFDEF WIN32} - which should be defined under Mingw). So, I have gone back to gcc-3.2.3, and the binaries that I will soon release will be based on gcc-3.2.3.
ATM as a workaround `--print-needed-options' will print you correct predefines which then should be given back to the compiler. Sounds silly, but in fact the compiler proper have the info, but it is not available in preprocessor, so one havwe to use options to pass the info back. For example on Linux:
gpc-build/gcc/xgpc -Bgpc-build/gcc/ --print-needed-options foo.pas
gives:
-D__x86_64 -D__x86_64__ -D__amd64 -D__amd64__ -D__tune_athlon__ -D__tune_athlon_sse__ -D__MMX__ -D__3dNOW__ -D__3dNOW_A__ -D__SSE__ -D__SSE2__ -D__SSE_MATH__ -D__SSE2_MATH__ -D__athlon -D__athlon__ -D__athlon_sse__ -Dlinux -D__linux -D__linux__ -Dunix -D__unix -D__unix__ -D__gnu_linux__ -D__ELF__ -D__LP64__ -D_LP64
Still, with 3.2.3 backend predefines are available without any additional effort.