On Wed, 6 Feb 2002, Patrik Stridvall wrote: [...]
I also so got some other strange error with PCONTEXT in winnt.h which in didn't understand.
You must define _X86_ before including 'winnt.h'. Otherwise it won't known on which architecture it's being compile and it won't define CONTEXT. And you must also include 'windef.h'. Otherwise CONST is not getting defined and again, errors ensue.
#define _X86_ #include <windef.h> #include <winnt.h>
Defining _X86_ is done in 'windows.h' which means that it is virtually impossible to use these headers without including the big beast itself.
Also, to answer Dimitrie:
On Wed, 6 Feb 2002, Dimitrie O. Paun wrote: [...]
Additionally windef.h must be included first.
#include "winbase.h" #include "windef.h"
doesn't work. You have to do
[...]
#include "windef.h" #include "winbase.h"
This is a minor issue though.
Which should be fixed, I think.
Windows does not support including 'winbase.h' first either so we don't really need to support it either. If you want to include 'winbase.h' yourself, on Windows you have to write:
#define _X86_ #include <windef.h> #include <winnt.h> #include <stdarg.h> #include <winbase.h>
Wine is already much more flexible. You can even just include 'windef.h' and it will include 'winnt.h' for you, how sophisticated!
More seriously, we could make it so that you can just #include <winbase.h> in Wine, but that may not be very easy and is obviously not required by Winelib.
-- Francois Gouget fgouget@free.fr http://fgouget.free.fr/ f u kn rd ts, ur wy 2 gky 4 ur wn gd.