[MPlayer-dev-eng] conflicting types of BITMAPINFOHEADER between libmpdemux/ms_hdr.h and windgi.h
Roberto Togni
rxt at rtogni.it
Fri Sep 14 20:32:12 CEST 2007
On Fri, 14 Sep 2007 04:06:53 +0200
Gianluigi Tiesi <mplayer at netfarm.it> wrote:
> I'm tring to compile latest svn on mingw,
> but the struct defined in ms_hdr.h BITMAPINFOHEADER
> is incompatible with the one in windgi.h,
> the only difference seams to be that wingdi.h doesn't
> declares the struct as packed, and defines inconditionately
> the struct, but using the one from wingdi.h I get a compilation error:
>
> In file included from libmpdemux/stheader.h:5,
> from command.c:10:
> libmpdemux/ms_hdr.h:64: error: expected specifier-qualifier-list before
> 'BITMAPINFOHEADER'
> In file included from command.c:10:
> libmpdemux/stheader.h:89: error: expected specifier-qualifier-list
> before 'BITMAPINFOHEADER'
> In file included from ./subreader.h:4,
> from libvo/sub.h:61,
> from command.c:13:
>
> wingdi.h in mingw has #pragma pack()
> does gcc really support this directive?
>
> it appears to me like a mingw header bug since the original ms include
> uses pack(), anyway to avoid at all the problem a solution
> may be defining as a private struct with different name.
>
> Latest mingw runtime causes a lot of internal warnings,
> I may find the time to fixup some of their includes
> but mingw team already rejected my 64bit file ops patch
>
> As a workaround I've added
>
> #ifndef _BITMAPINFOHEADER_
> #define _BITMAPINFOHEADER_
>
> in mingw wingdi.h so ms_hdr.h one is picked
>
> I've just tried to add packed attr on wingdi.h
> and I'm still getting the same error,
> by looking at the preprocessor output, it seams
> that the struct definition is not included, but it's very strange.
>
Does reverting r24446 fixes this?
Ciao,
Roberto
More information about the MPlayer-dev-eng
mailing list