[MPlayer-cygwin] Problems compiling with SDL

Sascha Sommer saschasommer at freenet.de
Fri Sep 15 15:59:42 CEST 2006


Hi,

On Friday 01 September 2006 05:22, John Brown wrote:
> ) ./configure fails because sdl-config --libs returns
> -Lc:/mingw/lib -lmingw32 -lSDLmain -lSDL -mwindows
> which is insufficient. -lwinmm and -ldxguid are also required.
> I modified sdl-config so that it returned
> -Lc:/mingw/lib -lmingw32 -lSDLmain -lSDL -lwinmm -ldxguid -mwindows
>

Imho this is a SDL bug it should not force things like -mwindows...

>
> 2) Duplicate symbol errors (IID_IDirectDraw7,IID_IDirectDrawcolorControl)
> in libdxguid.a and
> libvo/vo_directx.c. I looked in libvo/directx.c and found the following:
> * DirectDraw GUIDs.
> * Defining them here allows us to get rid of the dxguid library during
> * the linking stage.
> ***************************************************************************
>**/
>
> const GUID IID_IDirectDraw7 =
> {
> 	0x15e65ec0,0x3b9c,0x11d2,{0xb9,0x2f,0x00,0x60,0x97,0x97,0xea,0x5b}
> };
>
> const GUID IID_IDirectDrawColorControl =
> {
> 	0x4b9f0ee0,0x0d7e,0x11d0,{0x9b,0x06,0x00,0xa0,0xc9,0x03,0xa3,0xb8}
> };
>
> So what if dxguid has to be included? Remember, it is not included, then
> configure fails. It is part of w32api, although it seems that the
> current w32api headers do not define some constants used by MPlayer.
> After I upgraded w32api (thinking that maybe it was outdated), I had to
> re-install the MPlayer dx7 headers.
>
> Anyway, I commented out these definitions.
>

Would it also work if you make them static? Defining these GUIDs directly here 
makes MPlayer also work on systems without directx.


> 3) Finally, during link, the SDL libraries could not find GDI functions.
> It seems that the -mwindows was removed from the libs returned
> by sdl-config. To work around this, I added -lgdi32 so that sdl-config
> returned
> -Lc:/mingw/lib -lmingw32 -lSDLmain -lSDL -lwinmm -ldxguid -mwindows
> -lgdi32.
>

Is SDL working correct nowadays? It had some problems with the overlay when 
MPlayer was ported to windows.

Regards

Sascha



More information about the MPlayer-cygwin mailing list