diff options
author | Enrico Weigelt, metux IT consult <info@metux.net> | 2024-03-11 10:08:13 +0100 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2024-04-15 18:59:23 -0700 |
commit | 1ca48d0a48dbec38d2765d8626f7983751226966 (patch) | |
tree | 12c9e99c640386360f2e91b76d154a97e2a4cc91 | |
parent | 232cad9ec36631379b23ce29d577332f82565803 (diff) |
dix: workaround for win32 name clash on CreateWindow()
The problem is, ming32 headers unconditionally define CreateWindow() to
alias CreateWindowA() in winuser.h, which is included by windows.h, which
is included by *a lot* common headers. So it highly depends on the exact
include order, whether it works. (also weird things could happen, e.g.
the Xserver's CreateWindow() ending up renamed to CreateWindowA(), ...)
Until we've found a really clean solution to this problem (which might
involve fixing mingw32 first), just add a little workaround by undef'ing
CreateWindow symbol whereever necessary.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1355>
-rw-r--r-- | dix/dispatch.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/dix/dispatch.c b/dix/dispatch.c index 04a50259d..aeb9d0717 100644 --- a/dix/dispatch.c +++ b/dix/dispatch.c @@ -132,6 +132,9 @@ Equipment Corporation. #include "client.h" #include "xfixesint.h" +// temporary workaround for win32/mingw32 name clash +#undef CreateWindow + #ifdef XSERVER_DTRACE #include "probes.h" #endif |