aboutsummaryrefslogtreecommitdiff
path: root/ports/ffmpeg/0003-fix-windowsinclude.patch
diff options
context:
space:
mode:
Diffstat (limited to 'ports/ffmpeg/0003-fix-windowsinclude.patch')
-rw-r--r--ports/ffmpeg/0003-fix-windowsinclude.patch28
1 files changed, 28 insertions, 0 deletions
diff --git a/ports/ffmpeg/0003-fix-windowsinclude.patch b/ports/ffmpeg/0003-fix-windowsinclude.patch
new file mode 100644
index 000000000..8fe6a5474
--- /dev/null
+++ b/ports/ffmpeg/0003-fix-windowsinclude.patch
@@ -0,0 +1,28 @@
+diff --git a/fftools/cmdutils.c b/fftools/cmdutils.c
+index 9cfbc45..e3447e6 100644
+--- a/fftools/cmdutils.c
++++ b/fftools/cmdutils.c
+@@ -63,6 +63,8 @@
+ #include <sys/resource.h>
+ #endif
+ #ifdef _WIN32
++#define _WIN32_WINNT 0x0502
++#define WIN32_LEAN_AND_MEAN
+ #include <windows.h>
+ #endif
+
+diff --git a/fftools/ffmpeg.c b/fftools/ffmpeg.c
+index 01f0410..dbb0736 100644
+--- a/fftools/ffmpeg.c
++++ b/fftools/ffmpeg.c
+@@ -23,6 +23,10 @@
+ * multimedia converter based on the FFmpeg libraries
+ */
+
++#define _WIN32_WINNT 0x0502 // Must be less than 0x0600, because otherwise WinSock2.h defines "pollfd" which then gets redefined in "os_support.h".
++#define WIN32_LEAN_AND_MEAN
++
++
+ #include "config.h"
+ #include <ctype.h>
+ #include <string.h>