player/main: Fix Cygwin build

Xlib.h (included from x11_common.h) defines a macro 'Status' as 'int'.
This messed up a bunch of definitions in windows.h and broke the build
in Cygwin. Including windows.h first seems to solve the problem.

This commit also removes the definition of an unused flag.
This commit is contained in:
James Ross-Gowan 2014-03-13 12:16:15 +11:00 committed by wm4
parent d391e2d204
commit 5e698a7b39
1 changed files with 8 additions and 12 deletions

View File

@ -67,6 +67,14 @@
#include "command.h" #include "command.h"
#include "screenshot.h" #include "screenshot.h"
#if defined(__MINGW32__) || defined(__CYGWIN__)
#include <windows.h>
#ifndef BASE_SEARCH_PATH_ENABLE_SAFE_SEARCHMODE
#define BASE_SEARCH_PATH_ENABLE_SAFE_SEARCHMODE (0x0001)
#endif
#endif
#if HAVE_X11 #if HAVE_X11
#include "video/out/x11_common.h" #include "video/out/x11_common.h"
#endif #endif
@ -79,18 +87,6 @@
#include <pthread.h> #include <pthread.h>
#endif #endif
#if defined(__MINGW32__) || defined(__CYGWIN__)
#include <windows.h>
#ifndef BASE_SEARCH_PATH_ENABLE_SAFE_SEARCHMODE
#define BASE_SEARCH_PATH_ENABLE_SAFE_SEARCHMODE (0x0001)
#endif
#ifndef BASE_SEARCH_PATH_PERMANENT
#define BASE_SEARCH_PATH_PERMANENT (0x8000)
#endif
#endif
static bool terminal_initialized; static bool terminal_initialized;
const char mp_help_text[] = const char mp_help_text[] =