forked from bartvdbraak/blender
Fix for compilation with newer ffmpeg library
Error was cased by undefined UINT64_C in stdint.h for c++ programs. As I understand from ffmpeg mailing list the simpliest solution is to define __STDC_CONSTANT_MACROS before including ffmpeg libraries. There already was some amout of such definitions in the code and I've tested this with newer and older ffmpeg libraries -- this should work and should be safe, but maybe there is better way of fixing this problem.
This commit is contained in:
parent
b65cc25be3
commit
d33cef6974
@ -23,6 +23,9 @@
|
||||
* ***** END LGPL LICENSE BLOCK *****
|
||||
*/
|
||||
|
||||
// needed for INT64_C
|
||||
#define __STDC_CONSTANT_MACROS
|
||||
|
||||
#include "AUD_FFMPEGFactory.h"
|
||||
#include "AUD_FFMPEGReader.h"
|
||||
#include "AUD_Buffer.h"
|
||||
|
@ -27,6 +27,11 @@
|
||||
#include <cstring>
|
||||
#include <cmath>
|
||||
|
||||
#ifdef WITH_FFMPEG
|
||||
// needed for INT64_C
|
||||
#define __STDC_CONSTANT_MACROS
|
||||
#endif
|
||||
|
||||
#include "AUD_NULLDevice.h"
|
||||
#include "AUD_I3DDevice.h"
|
||||
#include "AUD_FileFactory.h"
|
||||
@ -62,6 +67,7 @@
|
||||
#include "AUD_JackDevice.h"
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef WITH_FFMPEG
|
||||
extern "C" {
|
||||
#include <libavformat/avformat.h>
|
||||
|
@ -29,6 +29,9 @@
|
||||
#include <cstring>
|
||||
|
||||
#ifdef WITH_FFMPEG
|
||||
// needed for INT64_C
|
||||
#define __STDC_CONSTANT_MACROS
|
||||
|
||||
#include "AUD_FFMPEGReader.h"
|
||||
#endif
|
||||
#ifdef WITH_SNDFILE
|
||||
|
Loading…
Reference in New Issue
Block a user