GNOME Bugzilla – Bug 585733
Wrong #include order in gstsegment.c
Last modified: 2009-06-14 19:05:43 UTC
GCC complains: In file included from gst_private.h:28, from gstsegment.c:25: ../config.h:311:1: error: "__MSVCRT_VERSION__" redefined In file included from c:\mingw\bin\../lib/gcc/mingw32/4.4.0/../../../../include/math.h:20, from gstsegment.c:23: c:\mingw\bin\../lib/gcc/mingw32/4.4.0/../../../../include/_mingw.h:213:1: error: this is the location of the previous definition This happens because gstsegment.c includes <math.h> before it includes "gst_private.h". <math.h> pulls <_mingw.h>, and <_mingw.h>, seeing that __MSVCRT_VERSION__ is not defined, defines it. Then "gst_private.h" pulls config.h, which redefines __MSVCRT_VERSION__
Created attachment 136554 [details] [review] Changes #include order to get config.h before _mingw.h
The patch is good but could you please use your real name for patches? :)
No, i could not. I have my reasons.
commit 18a34288cfdfc71a6bc2b6e1d6c59f5c64c23190 Author: Руслан Ижбулатов <lrn1986@gmail.com> Date: Sun Jun 14 16:56:32 2009 +0400 segment: fix include order to get config.h before _mingw.h config.h must always be included before any other includes, either directly or indirectly via gst_private.h. Fixes #585733.