[MPlayer-users] Mingw build problem

JonY 10walls at gmail.com
Fri Aug 17 11:12:44 CEST 2007


JonY wrote:
> Diego Biurrun wrote:
>> JonY wrote:
>>> I am trying to build mplayer r24076 on Windows XP
>>>
>>> gcc -D__USE_UNIX98 -D_GNU_SOURCE -I../libdvdcss 
>>> -DHAVE_DVDCSS_DVDCSS_H -I../libavcodec -I../libavformat 
>>> -Wdisabled-optimization -Wno-pointer-sign 
>>> -Wdeclaration-after-statement -I. -I.. -I../libavutil -Wall 
>>> -Wno-switch -Wpointer-arith -Wredundant-decls -O4 -march=i486 
>>> -mtune=generic -pipe -ffast-math -fomit-frame-pointer 
>>> -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE 
>>> -DHAVE_CONFIG_H -I/f/live -I/mingw/include/ -I/mingw/include/SDL 
>>> -D_GNU_SOURCE=1  -I/mingw/include/freetype2 -I/mingw/include 
>>> -I/mingw/include -I/mingw/include/dvdnav   -c -o dvd_reader.o 
>>> dvd_reader.c
>>> dvd_reader.c:205: error: static declaration of 'gettimeofday' follows 
>>> non-static declaration
>>> c:/mingw/include/sys/time.h:40: error: previous declaration of 
>>> 'gettimeofday' was here
>>> make[1]: *** [dvd_reader.o] Error 1
>>> make[1]: Leaving directory `/f/mplayer/dvdread'
>>> make: *** [dvdread/libdvdread.a] Error 2
>>>
>>> Which gettimeoday is supposed to be used?
>>
>> Please try again with Subversion HEAD, I may have fixed this.
>>
>> Diego
>>
>> _______________________________________________
>> MPlayer-users mailing list
>> MPlayer-users at mplayerhq.hu
>> http://lists.mplayerhq.hu/mailman/listinfo/mplayer-users
>>
> 
> Already done, svn HEAD builds fine.
> 
> Thanks.
> 
Sorry, ignore the previous message, I forgot to revert and clean up, SVN 
HEAD (r24084 as of writing) still fails.

removing the following lines from dvd_reader.c helps.

Index: dvd_reader.c
===================================================================
--- dvd_reader.c        (revision 24084)
+++ dvd_reader.c        (working copy)
@@ -189,19 +189,9 @@
    dev->align = align;
  }

-#ifdef WIN32 /* replacement gettimeofday implementation */
-#include <sys/timeb.h>
-static int gettimeofday( struct timeval *tv, void *tz )
-{
-  struct timeb t;
-  ftime( &t );
-  tv->tv_sec = t.time;
-  tv->tv_usec = t.millitm * 1000;
-  return 0;
-}
-#endif


+
  /* Loop over all titles and call dvdcss_title to crack the keys. */
  static int initAllCSSKeys( dvd_reader_t *dvd )
  {






More information about the MPlayer-users mailing list