# HG changeset patch # User reimar # Date 1262454071 0 # Node ID 774aa6f7399e9a6eed67c3e8436c57f20e2c2ecb # Parent d06ac0e5d63bf30edd85efb214f5aed279c25e6a Several hacks to fix compilation of tvi_dshow on MinGW64. diff -r d06ac0e5d63b -r 774aa6f7399e loader/wine/basetsd.h --- a/loader/wine/basetsd.h Sat Jan 02 16:55:41 2010 +0000 +++ b/loader/wine/basetsd.h Sat Jan 02 17:41:11 2010 +0000 @@ -72,8 +72,8 @@ #if defined(_WIN64) -typedef __uint32 __ptr32; -typedef void *__ptr64; +//typedef __uint32 __ptr32; +//typedef void *__ptr64; #else /* FIXME: defined(_WIN32) */ diff -r d06ac0e5d63b -r 774aa6f7399e loader/wine/winnt.h --- a/loader/wine/winnt.h Sat Jan 02 16:55:41 2010 +0000 +++ b/loader/wine/winnt.h Sat Jan 02 17:41:11 2010 +0000 @@ -620,7 +620,8 @@ #endif /* __sparc__ */ #if !defined(CONTEXT_FULL) && !defined(RC_INVOKED) -#error You need to define a CONTEXT for your CPU +#warning You need to define a CONTEXT for your CPU +typedef void CONTEXT; #endif typedef CONTEXT *PCONTEXT; @@ -747,7 +748,7 @@ #endif /* __sparc__ */ #ifndef DEFINE_REGS_ENTRYPOINT_0 -#error You need to define DEFINE_REGS_ENTRYPOINT macros for your CPU +#warning You need to define DEFINE_REGS_ENTRYPOINT macros for your CPU #endif #ifdef __i386__ @@ -758,7 +759,7 @@ #endif #if !defined(GET_IP) && !defined(RC_INVOKED) -# error You must define GET_IP for this CPU +#warning You must define GET_IP for this CPU #endif /* diff -r d06ac0e5d63b -r 774aa6f7399e stream/tvi_dshow.c --- a/stream/tvi_dshow.c Sat Jan 02 16:55:41 2010 +0000 +++ b/stream/tvi_dshow.c Sat Jan 02 17:41:11 2010 +0000 @@ -89,6 +89,11 @@ #include "tvi_dshow.h" +#ifndef STDCALL +// mingw64 needs this +#define STDCALL __stdcall +#endif + static tvi_handle_t *tvi_init_dshow(tv_param_t* tv_param); /* diff -r d06ac0e5d63b -r 774aa6f7399e stream/tvi_dshow.h --- a/stream/tvi_dshow.h Sat Jan 02 16:55:41 2010 +0000 +++ b/stream/tvi_dshow.h Sat Jan 02 17:41:11 2010 +0000 @@ -434,6 +434,8 @@ STDMETHOD(get_CrossbarPinInfo) (THIS_ BOOL, long, long *, long *); }; +#ifndef __IPropertyBag_INTERFACE_DEFINED__ +#define __IPropertyBag_INTERFACE_DEFINED__ #undef INTERFACE #define INTERFACE IPropertyBag DECLARE_INTERFACE(IPropertyBag) @@ -444,6 +446,7 @@ STDMETHOD(Read) (THIS_ LPCOLESTR, LPVARIANT, LPERRORLOG); STDMETHOD(Write) (THIS_ LPCOLESTR, LPVARIANT); }; +#endif #undef INTERFACE #define INTERFACE IAMStreamConfig @@ -678,6 +681,19 @@ STDMETHOD(IsCursorHidden) (THIS_ long *); }; +#ifndef DECLARE_ENUMERATOR_ +#define DECLARE_ENUMERATOR_(I,T) \ + DECLARE_INTERFACE_(I,IUnknown) \ + { \ + STDMETHOD(QueryInterface)(I*, REFIID,PVOID*); \ + STDMETHOD_(ULONG,AddRef)(I*); \ + STDMETHOD_(ULONG,Release)(I*); \ + STDMETHOD(Next)(I*, ULONG,T*,ULONG*); \ + STDMETHOD(Skip)(I*, ULONG); \ + STDMETHOD(Reset)(I*); \ + STDMETHOD(Clone)(I*, I**); \ + } +#endif DECLARE_ENUMERATOR_(IEnumFilters, LPBASEFILTER); DECLARE_ENUMERATOR_(IEnumPins, LPPIN); DECLARE_ENUMERATOR_(IEnumMediaTypes, AM_MEDIA_TYPE *);