[FFmpeg-devel] [PATCH] Fix vf_libopencv compilation problem in Mac OS X
thilo.borgmann at googlemail.com
Wed Apr 20 14:31:59 CEST 2011
Am 20.04.11 12:23, schrieb Roger Pau Monné:
> 2011/4/20 Thilo Borgmann <thilo.borgmann at googlemail.com>:
>> Am 20.04.11 11:02, schrieb Roger Pau Monné:
>>> Sorry, I didn't realize I've sent the file, I had the patch prepared,
>>> don't know why I sent that... Anyway the bug is the same as the one
>>> described here: http://www.openradar.me/8026390. Don't know if there
>>> is another way to fix this, I've only been able to find this solution.
>>> 2011/4/20 Carl Eugen Hoyos <cehoyos at ag.or.at>:
>>>> Roger Pau Monné <roger.pau <at> entel.upc.edu> writes:
>>>>> Just added a couple of macros to allow compilation of vf_libopencv in
>>>>> Mac OS X. Tested on Mac OS X 10.6.7, gcc 4.2.1 and OpenCV 2.2.
>> Has this really been tested with OpenCV >= 2.2?
> It has been tested with this release
> (OpenCV 2.2 stable, installed from brew)
I downloaded from a mirror yesterday and this file is not in there. I suspect
the file is left from a previous installation on your system then?
>>> Signed-off-by: Roger Pau Monné <roger.pau at entel.upc.edu>
>>> libavfilter/vf_libopencv.c | 6 ++++++
>>> 1 files changed, 6 insertions(+), 0 deletions(-)
>>> diff --git a/libavfilter/vf_libopencv.c b/libavfilter/vf_libopencv.c
>>> index 8401b4d..c1e57c6 100644
>>> --- a/libavfilter/vf_libopencv.c
>>> +++ b/libavfilter/vf_libopencv.c
>>> @@ -25,6 +25,12 @@
>>> /* #define DEBUG */
>>> +#ifndef NeXTBSD /* Allow compilation on NeXT and Darwin */
>>> +#ifdef __APPLE__
>>> + #undef __GNUC_STDC_INLINE__
>>> #include <opencv/cv.h>
>>> #include <opencv/cxtypes.h>
>> There's a report on FFmpeg-user complaining and myself ensured that this file
>> has been disappeared in OpenCV 2.2. Thus it should not compile against 2.2.
>> Or has this been fixed elsewhere in the mean time?
> I haven't been able to compile FFmpeg with OpenCV without adding the
> #undef, although I don't know if it's really the best way to do it
I mean the include of a missing file. Your #undef patch maybe fine though I've
not had the time to review it.
More information about the ffmpeg-devel