Fix libnut/ffmpeg compilation on i686-pc-mingw32

Fixes #255.

Signed-off-by: Timothy Gu <timothygu99@gmail.com>
This commit is contained in:
Timothy Gu 2013-10-14 17:56:34 -07:00
parent c561942a2e
commit df1ac4655c
1 changed files with 15 additions and 0 deletions

View File

@ -0,0 +1,15 @@
diff --git a/libnut/priv.h b/libnut/priv.h
index 5183503..aac2952 100644
--- a/libnut/priv.h
+++ b/libnut/priv.h
@@ -44,6 +44,10 @@
#define MAX(a,b) ((a) > (b) ? (a) : (b))
#define ABS(a) ((a) > 0 ? (a) : -(a))
+#if (defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR))
+#define ftello(a) (off_t)(_ftelli64(a))
+#endif
+
typedef struct {
nut_input_stream_tt isc;
int is_mem;