[FFmpeg-devel] use of UINT64_C in libavutil/common.h
Thu May 6 14:32:39 CEST 2010
On 05/ 6/10 08:27 AM, M?ns Rullg?rd wrote:
> What makes you think it should work with C++?
It doesn't, unless you enclose it in extern "C".
>> This define is defined in<stdint.h> The simple include<stdint.h>
>> should either be replaced by:
>> #ifdef __cplusplus
>> #define __STDC_CONSTANT_MACROS
>> #ifdef _STDINT_H
>> #undef _STDINT_H
>> # include<stdint.h>
> You have got to be kidding me.
_STDINT_H is platform-dependent and undefining is sure to cause your
compilation to fail or at the very least emit a lot of warnings. Also,
none of the ffmpeg headers contain any C++ workarounds, not even the
simple ones like wrapping around extern "C".
If you want it to work, either add -D__STDC_CONSTANT_MACROS to your
build scripts or #define __STDC_CONSTANT_MACROS just before including
the ffmpeg headers.
More information about the ffmpeg-devel