OpenCV2.4.9移植ARM,Ubuntu12.04

在尝试将OpenCV2.4.9从Ubuntu 12.04交叉编译到ARM平台时,遇到了错误,包括'CODEC_ID_H264'等未声明的错误。这可能与FFmpeg编解码器的定义不匹配或者库路径问题有关。解决方法可能涉及检查编译配置、更新FFmpeg头文件或重新设置环境变量。
摘要由CSDN通过智能技术生成

最近参考http://blog.csdn.net/stihy/article/details/51288743这个网址准备在Ubuntu里面交叉编译OpenCV2.4.9,不过在最后一步make的时候出现以下错误

cc1plus: warning: include location "/usr/local/include" is unsafe for cross-compilation [-Wpoison-system-directories]
In file included from /usr/local/arm/opencv-2.4.9/modules/highgui/src/cap_ffmpeg_impl.hpp:60,
                 from /usr/local/arm/opencv-2.4.9/modules/highgui/src/cap_ffmpeg.cpp:45:
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:104: error: 'CODEC_ID_H264' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:105: error: 'CODEC_ID_H264' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:106: error: 'CODEC_ID_H264' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:107: error: 'CODEC_ID_H264' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:108: error: 'CODEC_ID_H264' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:109: error: 'CODEC_ID_H264' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:111: error: 'CODEC_ID_H263' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:112: error: 'CODEC_ID_H263P' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:113: error: 'CODEC_ID_H263I' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:114: error: 'CODEC_ID_H261' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:117: error: 'CODEC_ID_H263P' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:118: error: 'CODEC_ID_H263P' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:120: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:121: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:122: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:123: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:124: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:125: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:126: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:129: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:130: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:131: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:132: error: 'CODEC_ID_MPEG4' was not declared in this scope
/usr/local/arm/opencv-2.4.9/modules/highgui/src/ffmpeg_codecs.hpp:133: error: 'CODEC_ID_MPEG4' was not declared in this

评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值