From: Angus L. <le...@ly...> - 2005-09-29 15:23:33
|
Greg Chicares wrote: > To find out what macros are always predefined: > touch eraseme.h; /MinGW/bin/cpp -dM eraseme.h > To find out what macros are defined when you include any mingw header: > echo "#include <stdio.h>" > eraseme.h; /MinGW/bin/cpp -dM eraseme.h > It might be useful to replace <stdio.h> with <w32api.h> in that last > command, for the present purpose. Almost perfect! $ grep W32API /mnt/windowsJ/MinGW/include/* /mnt/windowsJ/MinGW/include/w32api.h:#ifndef _W32API_H_ /mnt/windowsJ/MinGW/include/w32api.h:#define _W32API_H_ /mnt/windowsJ/MinGW/include/w32api.h:#define __W32API_VERSION 3.1 /mnt/windowsJ/MinGW/include/w32api.h:#define __W32API_MAJOR_VERSION 3 /mnt/windowsJ/MinGW/include/w32api.h:#define __W32API_MINOR_VERSION 1 /mnt/windowsJ/MinGW/include/w32api.h:#endif /* ndef _W32API_H_ */ However: $ grep -i w32api.h /mnt/windowsJ/MinGW/include/* /mnt/windowsJ/MinGW/include/w32api.h:#ifndef _W32API_H_ /mnt/windowsJ/MinGW/include/w32api.h:#define _W32API_H_ /mnt/windowsJ/MinGW/include/w32api.h:#endif /* ndef _W32API_H_ */ /mnt/windowsJ/MinGW/include/winuser.h: in the w32api headers. I've left it here for documentation purposes. Why don't the winapi header files #include this file? So clearly I can write an autoconf test to see whether this file exists, but I can't use the __W32API_VERSION directly in my own code :( Angus |