This is the mail archive of the
mailing list for the Cygwin project.
Re: w32api header problems
Wednesday, 09 January, 2002 Jean le Roux firstname.lastname@example.org wrote:
JlR> On Wed, Jan 09, 2002 at 01:07:47PM +0300, egor duda wrote:
>> Wednesday, 09 January, 2002 Jean le Roux email@example.com wrote:
>> JlR> I need to include /usr/include/w32api/winbase.h in order to use the
>> JlR> GetVolumeInformation(...) system call under windows.
>> JlR> However, as i metioned in an earlier mail, DWORD seems to not be
>> JlR> defined. I tracked DWORD's definition down to windef.h.. but it seems
>> JlR> the whole include chain is a bit funny.. there are lots of
>> JlR> inter-dependencies which are not satisfied.
>> JlR> Does anyone have any words of wisdom to make life a little easier, or
>> JlR> do I simply have to test for, and include, all the headers in w32api ?
>> you ought to
>> #include <windows.h>
JlR> I've done this but <windows.h> seems to leave my code in a tangle :)
JlR> I suddenly have parse errors in my own header files, on normal
JlR> function declerations. I can only deduce that windows.h is leaving an
JlR> open ifdef or has unterminated strings or something silly.
it's easy to find out what the reason is. gcc has a very useful option
'--save-temps'. it instructs preprocessor, compiler and assembler to
leave their temporary files in place, so if you compiling, say, zzz.c,
you'll get zzz.i (output of preprocessor), zzz.s (assembly source --
output of compiler) and zzz.o (compiled binary object). You want to
look into zzz.i it shows what your source file turns into, and it's
almost always easy to see why.
Egor. mailto:firstname.lastname@example.org ICQ 5165414 FidoNet 2:5020/496.19
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html