summaryrefslogtreecommitdiffstats
path: root/player
diff options
context:
space:
mode:
authorJames Ross-Gowan <rossymiles@gmail.com>2014-03-13 12:16:15 +1100
committerwm4 <wm4@nowhere>2014-03-13 14:36:20 +0100
commit5e698a7b39cd8cd4549014421521addcd28761c1 (patch)
treec5233170b0c8af1409753a1b710723c6b9609b39 /player
parentd391e2d20491d99789a81edc515bfc8cef978478 (diff)
downloadmpv-5e698a7b39cd8cd4549014421521addcd28761c1.tar.bz2
mpv-5e698a7b39cd8cd4549014421521addcd28761c1.tar.xz
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.
Diffstat (limited to 'player')
-rw-r--r--player/main.c20
1 files changed, 8 insertions, 12 deletions
diff --git a/player/main.c b/player/main.c
index bf97a39a3a..de88d0b817 100644
--- a/player/main.c
+++ b/player/main.c
@@ -67,6 +67,14 @@
#include "command.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
#include "video/out/x11_common.h"
#endif
@@ -79,18 +87,6 @@
#include <pthread.h>
#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;
const char mp_help_text[] =