将OpenCv框架包含在IOS本地扩展中时出错 [英] Error when including OpenCv framework in a Native Extension for IOS
本文介绍了将OpenCv框架包含在IOS本地扩展中时出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我为实现OpenCV框架的IOS创建了一个ANE,但是当我在Flash Builder上编译应用程序时,出现这个错误:
<
未定义符号体系结构的ARMv7:
的__ZNKSt3__120__vector_base_commonILb1EE20__throw_length_errorEv,引用从:code>而打包应用程序时发生错误在opencv2
__ZNSt3__16vectorIN2cv3VecIiLi128EEENS_9allocatorIS3_EEE8__appendEm(matrix.o)$在opencv2在opencv2在opencv2 b $ b __ZNSt3__16vectorIN2cv3VecIiLi64EEENS_9allocatorIS3_EEE8__appendEm(matrix.o)
__ZNSt3__16vectorIN2cv3VecIiLi32EEENS_9allocatorIS3_EEE8__appendEm(matrix.o)
__ZNSt3__16vectorIN2cv3VecIiLi16EEENS_9allocatorIS3_EEE8__appendEm(matrix.o)在opencv2
__ZNSt3__16vectorIN2cv3VecIiLi12EEENS_9allocatorIS3_EEE8__appendEm(matrix.o)
__ZNSt3__16vectorIN2cv3VecIiLi9EEENS_9allocatorIS3_EEE8__appendEm in opencv2(matrix.o)
__ZNSt3__16vectorIN2cv3VecIiLi8EEENS_9alloc atorIS3_EEE8__appendEm in opencv2(matrix.o)
...
ld:符号(s)未找到架构armv7
执行时编译失败:ld64
在我添加这行后发生了错误
< option> -framework opencv2< / option>
到platformOptions.xml上的linkerOption
有什么想法?
解决方案
问题解决了。
我已经添加了这一行
< option> -lc ++< / option>
加入到platformOptions.xml。
现在OpenCV在我的ActionScript原生扩展中效果很好。
I'm creating an ANE for IOS that implements the OpenCV framework, but when I compile the app on Flash Builder I get this error:
Error occurred while packaging the application:
Undefined symbols for architecture armv7:
"__ZNKSt3__120__vector_base_commonILb1EE20__throw_length_errorEv", referenced from:
__ZNSt3__16vectorIN2cv3VecIiLi128EEENS_9allocatorIS3_EEE8__appendEm in opencv2(matrix.o)
__ZNSt3__16vectorIN2cv3VecIiLi64EEENS_9allocatorIS3_EEE8__appendEm in opencv2(matrix.o)
__ZNSt3__16vectorIN2cv3VecIiLi32EEENS_9allocatorIS3_EEE8__appendEm in opencv2(matrix.o)
__ZNSt3__16vectorIN2cv3VecIiLi16EEENS_9allocatorIS3_EEE8__appendEm in opencv2(matrix.o)
__ZNSt3__16vectorIN2cv3VecIiLi12EEENS_9allocatorIS3_EEE8__appendEm in opencv2(matrix.o)
__ZNSt3__16vectorIN2cv3VecIiLi9EEENS_9allocatorIS3_EEE8__appendEm in opencv2(matrix.o)
__ZNSt3__16vectorIN2cv3VecIiLi8EEENS_9allocatorIS3_EEE8__appendEm in opencv2(matrix.o)
...
ld: symbol(s) not found for architecture armv7
Compilation failed while executing : ld64
The error occurred after I added this line
<option>-framework opencv2</option>
to the linkerOption on the platformOptions.xml
Any idea?
解决方案
Problem solved. I've added this line
<option>-lc++</option>
to the platformOptions.xml.
Now OpenCV works great in my actionscript native extension.
这篇关于将OpenCv框架包含在IOS本地扩展中时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文