[MPlayer-dev-eng] fix compilation errors with mingw64
Diego Biurrun
diego at biurrun.de
Wed May 4 11:17:25 CEST 2011
On Fri, Apr 29, 2011 at 06:35:50PM +0000, Stephen Sheldon wrote:
> Diego Biurrun <diego <at> biurrun.de> writes:
>
> >
> > On Tue, Apr 26, 2011 at 09:49:49AM -0700, Stephen Sheldon wrote:
> > > I use mingw64 to compile mplayer in Windows 7 64-bits. I use the
> > > mingw64-x86_64 packages on cygwin. After the recent change to configure
> > > to add the flag "-Werror-implicit-funtion-declaration" I got 3
> > > compilation errors. Attached is a patch to fix them.
> >
> > Show us the errors please.
> >
> Here is the error for swab:
>
> x86_64-w64-mingw32-gcc -MD -MP -Wundef -Wall -Wno-switch -Wno-parentheses
> -Wpointer-arith -Wredundant-decls -Werror-implicit-function-declaration
> -Wstrict-prototypes -Wmissing-prototypes -Wdisabled-optimization
> -Wno-pointer-sign -Wdeclaration-after-statement -std=gnu99 -O4 -march=native
> -mtune=native -pipe -ffast-math -fomit-frame-pointer -D_LARGEFILE_SOURCE
> -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -Ilibdvdread4 -I. -Iffmpeg
> -I/mingw64/include -fno-common -DPIC -I/mingw64/include/freetype2
> -I/mingw64/include -I/mingw64/include -DFF_API_MAX_STREAMS=0 -c -o command.o
> command.c
> In file included from libmpdemux/aviheader.h:26:0,
> from libmpdemux/stheader.h:23,
> from command.c:29:
> ./mpbswap.h:35:6: error: conflicting types for 'swab'
> /usr/x86_64-w64-mingw32/sys-root/mingw/include/stdlib.h:585:16: note: previous
> declaration of 'swab' was here
> make: *** [command.o] Error 1
>
> configure has already been updated to check for string.h. It would be great if
> it could also check for stdlib.h.
No, this is a slippery slope that we should not descend down further.
On the contrary, I'm tempted to remove the string.h hack again. MinGW64
needs to be fixed instead.
Diego
P.S.: Please don't bottom-post, use interleaved quoting with trimmed
quotes instead.
More information about the MPlayer-dev-eng
mailing list