diff --git a/graphics/ddraw.c b/graphics/ddraw.c index fe1d2d43dd3..b1b36f8abc8 100644 --- a/graphics/ddraw.c +++ b/graphics/ddraw.c @@ -21,16 +21,15 @@ #include #include #include +#include "windows.h" #ifdef HAVE_LIBXXF86VM -/* X is retarted and insists on declaring INT32, INT16 etc in Xmd.h, this is a crude hack to get around it */ -/* Anywhere ts_xf86vmode.h is included you must define LONG64 also, see include/wintypes.h */ -#define LONG64 +/* X is retarted and insists on declaring INT32, INT16 etc in Xmd.h, + this is a crude hack to get around it */ +#define XMD_H #include "ts_xf86vmode.h" -#undef LONG64 #endif -#include "windows.h" #include "winerror.h" #include "interfaces.h" #include "gdi.h" diff --git a/tools/make_X11wrappers b/tools/make_X11wrappers index 4d01c2d2214..2784515cceb 100755 --- a/tools/make_X11wrappers +++ b/tools/make_X11wrappers @@ -63,7 +63,7 @@ foreach $name (@dolist) { if($name eq "xf86vmode") { $x11_incl = "#include \n"; $extensions_dir = "extensions/"; - $pre_file = "#include \"config.h\"\n#ifdef HAVE_LIBXXF86VM\n"; + $pre_file = "#include \"wintypes.h\"\n#ifdef HAVE_LIBXXF86VM\n#define XMD_H\n"; $post_file = "#endif"; } diff --git a/tsx11/ts_xf86vmode.c b/tsx11/ts_xf86vmode.c index edc1697a3fb..e4e7df5a3ec 100644 --- a/tsx11/ts_xf86vmode.c +++ b/tsx11/ts_xf86vmode.c @@ -3,8 +3,9 @@ * This file was generated automatically by tools/make_X11wrappers * DO NOT EDIT! */ -#include "config.h" +#include "wintypes.h" #ifdef HAVE_LIBXXF86VM +#define XMD_H #include #include