[MPlayer-dev-eng] [PATCH] Fix a bunch of fresh -Wundef warnings...

Erik Auerswald auerswal at unix-ag.uni-kl.de
Sun Oct 28 23:37:12 CET 2012


On 10/28/2012 10:00 PM, Alexander Strasser wrote:
> Erik Auerswald wrote:
>> On 10/28/2012 01:44 AM, Alexander Strasser wrote:
>>> Erik Auerswald wrote:
>>>> On 10/25/2012 10:51 PM, Erik Auerswald wrote:
>>>>> compiling a current svn checkout of MPlayer with a current git clone of
>>>>> FFmpeg shows the following new warnings:
>>>>>
>>>>> libavutil/libm.h:36:6: warning: "HAVE_ATANF" is not defined [-Wundef]
>>>>> libavutil/libm.h:41:6: warning: "HAVE_ATAN2F" is not defined [-Wundef]
>>>>> libavutil/libm.h:46:6: warning: "HAVE_POWF" is not defined [-Wundef]
>>>>> libavutil/libm.h:58:6: warning: "HAVE_COSF" is not defined [-Wundef]
>>>>> libavutil/libm.h:63:6: warning: "HAVE_EXPF" is not defined [-Wundef]
>>>>> libavutil/libm.h:98:6: warning: "HAVE_LDEXPF" is not defined [-Wundef]
>>>>> libavutil/libm.h:123:6: warning: "HAVE_LOG10F" is not defined [-Wundef]
>>>>> libavutil/libm.h:128:6: warning: "HAVE_SINF" is not defined [-Wundef]
>>>>>
>>>>> Seems some new FFmpeg #defines that need to be added somewhere™. Does
>>>>> anybody know where new FFmpeg feature test macros are supposed to be
>>>>> added? More specific than "to configure", please. ;-)
>>>>
>>>> The attached patch adds checks to create the above HAVE_* defines to
>>>> configure. The many silenced warnings show additional missing HAVE_*
>>>> defines...
>>>
>>>    your patch looks good to me.
>>
>> Thanks for looking into the issue. :-)
>>
>>> Also if I am not too tired it actually
>>> does fix a few wrong decisions (on some systems libm.h will redefine
>>> math functions that are actually there) as opposed to only silencing
>>> warnings.
>>
>> I thought so, but did not check and thus did not claim more than
>> fixing warnings. I did test that the defines are sensible (all
>> functions detected on my system) and the resulting MPlayer still
>> works for me... ;-)
>>
>>>    I will commit Sunday evening if I hear no objections.
>
>    Committed.

Thanks.

I still get the following -Wundef warnings:

libdvdcss/libdvdcss.c:123:5: warning: "HAVE_DIRECT_H" is not defined 
[-Wundef]
libdvdcss/libdvdcss.c:241:5: warning: "HAVE_DIRECT_H" is not defined 
[-Wundef]
libavformat/cache.c:36:5: warning: "HAVE_IO_H" is not defined [-Wundef]
libavformat/file.c:26:5: warning: "HAVE_IO_H" is not defined [-Wundef]
libavformat/udp.c:230:5: warning: "HAVE_STRUCT_GROUP_SOURCE_REQ" is not 
defined [-Wundef]
libavformat/udp.c:258:7: warning: "HAVE_STRUCT_IP_MREQ_SOURCE" is not 
defined [-Wundef]
libavcodec/pthread.c:34:5: warning: "HAVE_SCHED_GETAFFINITY" is not 
defined [-Wundef]
libavcodec/pthread.c:38:5: warning: "HAVE_GETPROCESSAFFINITYMASK" is not 
defined [-Wundef]
libavcodec/pthread.c:41:5: warning: "HAVE_SYSCTL" is not defined [-Wundef]
libavcodec/pthread.c:49:5: warning: "HAVE_SYSCONF" is not defined [-Wundef]
libavcodec/pthread.c:168:5: warning: "HAVE_SCHED_GETAFFINITY" is not 
defined [-Wundef]
libavcodec/pthread.c:177:7: warning: "HAVE_GETPROCESSAFFINITYMASK" is 
not defined [-Wundef]
libavcodec/pthread.c:182:7: warning: "HAVE_SYSCTL" is not defined [-Wundef]
libavcodec/pthread.c:189:7: warning: "HAVE_SYSCONF" is not defined [-Wundef]
libavcodec/pthread.c:191:7: warning: "HAVE_SYSCONF" is not defined [-Wundef]
libswscale/utils.c:1095:5: warning: "HAVE_MPROTECT" is not defined [-Wundef]
libswscale/utils.c:1126:5: warning: "HAVE_MPROTECT" is not defined [-Wundef]
libswscale/utils.c:1723:5: warning: "HAVE_MPROTECT" is not defined [-Wundef]
libavutil/mem.c:99:7: warning: "HAVE_ALIGNED_MALLOC" is not defined 
[-Wundef]
libavutil/mem.c:160:7: warning: "HAVE_ALIGNED_MALLOC" is not defined 
[-Wundef]
libavutil/mem.c:187:7: warning: "HAVE_ALIGNED_MALLOC" is not defined 
[-Wundef]
libavutil/random_seed.c:26:5: warning: "HAVE_CRYPTGENRANDOM" is not 
defined [-Wundef]
libavutil/random_seed.c:109:5: warning: "HAVE_CRYPTGENRANDOM" is not 
defined [-Wundef]
libavutil/time.c:32:5: warning: "HAVE_WINDOWS_H" is not defined [-Wundef]
libavutil/time.c:45:7: warning: "HAVE_GETSYSTEMTIMEASFILETIME" is not 
defined [-Wundef]
libavutil/time.c:62:7: warning: "HAVE_USLEEP" is not defined [-Wundef]
libavutil/time.c:64:7: warning: "HAVE_SLEEP" is not defined [-Wundef]

Build system is Debian/Sid.

$ uname -a
Linux abc 3.2.0-4-686-pae #1 SMP Debian 3.2.32-1 i686 GNU/Linux

I don't know when (or if) I'll find the time to work on this.

Erik


More information about the MPlayer-dev-eng mailing list