Unforunately OpenCV的经理已经停止OpenCV的2.4.3适用于Android 4.2(Mac OSX版10.7) [英] Unforunately OpenCV Manager has stopped in OpenCV 2.4.3 for android 4.2 ( Mac OSX 10.7)

查看:218
本文介绍了Unforunately OpenCV的经理已经停止OpenCV的2.4.3适用于Android 4.2(Mac OSX版10.7)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在运行OpenCV的样本项目(3 - 4)有问题。我运行程序每次,我发现这个问题Unforunately OpenCV的经理已停止出现在我的Andr​​oid模拟器。

每次出现,我叫这个问题。

OpenCVLoader.initAsync(OpenCVLoader.OPENCV_VERSION_2_4_3,对此,mLoaderCallback);

我跟着这个页面
<一href=\"http://docs.opencv.org/doc/tutorials/introduction/android_binary_package/dev_with_OCV_on_Android.html\" rel=\"nofollow\">http://docs.opencv.org/doc/tutorials/introduction/android_binary_package/dev_with_OCV_on_Android.html

这是我的警告消息


  

/Applications/eclipse-android/android-ndk-r8c/toolchains/arm-linux-androideabi-4.6/$p$pbuilt/darwin-x86/bin/../lib/gcc/arm-linux-androideabi/4.6/../../../../arm-linux-androideabi/bin/ld:
  警告:隐藏符号'__aeabi_atexit在
  ./obj/local/armeabi-v7a/libgnustl_static.a(a​​texit_arm.o)被引用
  通过DSO
  /Applications/eclipse-android/OpenCV-2.4.3-android-sdk/sdk/native/jni/../libs/armeabi-v7a/libopencv_java.so


logcat中(来自OpenCV的sample4):


  

gralloc_goldfish,没有GPU org.opencv.samples.tutorial4模拟器
  仿真检测。


请注意:


  1. 我的Java兼容级别为1.6,因为我有一些问题,编译OpenCV的C ++文件。
    (遵循了这一页:<一href=\"http://stackoverflow.com/questions/1678122/must-override-a-superclass-method-errors-after-importing-a-project-into-eclips\">'Must导入项目到Eclipse 后覆盖一个超类方法错误)


  2. 我安装ADB既OpenCV_2.4.3_binary_pack_armv7a.apk和OpenCV_2.4.3_Manager_2.0_armeabi-v7a.apk


  3. 我用三星Galaxy S作为我的手机模拟器


解决方案

我碰到了同样的问题:
隐藏符号'__aeabi_atexitarmeabi-V7A / libgnustl_static.a(atexit_arm.o)由DSO引用

我使用JNI OpenCV的测试,与之前的工作我已经加入它的应用程序。
我曾试图改变的ARMv7-A机armeabi在Application.mk
我也尝试添加到上述项目中提到的所有路径 - >属性 - > C / C ++常规 - >路径和符号。

它没有工作。
感谢我的球队领袖,我已经找到了解决办法:

在Application.mk,您需要更改APP_STL:= gnustl_static
到APP_STL:= gnustl_shared。这是因为LIB apparantly在编译共享,而不是静态的。
此外,添加到调用LoadLibrary区的lib:的System.loadLibrary(gnustl_shared);
这应在静态区域上进行,如下:

 静态{
       尝试{
           的System.loadLibrary(gnustl_shared);
           //做 - 添加静态code
       }
       赶上(的UnsatisfiedLinkError E){
            Log.v(TAG,乡土code库加载失败\\ n+ E);
       }
       赶上(例外五){
            Log.v(TAG,异常:+ E);
       }
   }

这就是它!它解决了我的问题...
希望它帮助。

因巴尔

I have a problem running openCV samples project (3 - 4). Everytime that I run the program, I found the problem "Unforunately OpenCV Manager has stopped" displays in my Android emulator.

The problem occurs everytime that I call

OpenCVLoader.initAsync(OpenCVLoader.OPENCV_VERSION_2_4_3, this, mLoaderCallback);

I followed this page http://docs.opencv.org/doc/tutorials/introduction/android_binary_package/dev_with_OCV_on_Android.html

This is the Warning Message that I have

/Applications/eclipse-android/android-ndk-r8c/toolchains/arm-linux-androideabi-4.6/prebuilt/darwin-x86/bin/../lib/gcc/arm-linux-androideabi/4.6/../../../../arm-linux-androideabi/bin/ld: warning: hidden symbol '__aeabi_atexit' in ./obj/local/armeabi-v7a/libgnustl_static.a(atexit_arm.o) is referenced by DSO /Applications/eclipse-android/OpenCV-2.4.3-android-sdk/sdk/native/jni/../libs/armeabi-v7a/libopencv_java.so

Logcat (from OpenCV sample4):

gralloc_goldfish, org.opencv.samples.tutorial4 Emulator without GPU emulation detected.

Note:

  1. I set java compliance level to 1.6 since I have some problem compiling OpenCV c++ file. (followed this page: 'Must Override a Superclass Method' Errors after importing a project into Eclipse)

  2. I install adb with both OpenCV_2.4.3_binary_pack_armv7a.apk and OpenCV_2.4.3_Manager_2.0_armeabi-v7a.apk

  3. I used Samsung Galaxy S as my cellphone emulator

解决方案

I run into the same problem: hidden symbol '__aeabi_atexit' armeabi-v7a/libgnustl_static.a(atexit_arm.o) is referenced by DSO

I am using the opencv test in jni, with an application that worked before I have added it. I have tried to change the ARMv7-A machine to armeabi in the "Application.mk' I have also tried to add all the paths mentioned above to the Project -> Properties -> C/C++ General -> Path and Symbols.

It didn't work. Thanks to my team leader, I have found the solution:

in Application.mk, You need to change the APP_STL := gnustl_static to APP_STL := gnustl_shared. This is because the lib apparantly was compiled in shared instead of static. In addition, add to the loadlibrary area the lib: System.loadLibrary("gnustl_shared"); This should be done in a static area, as followed:

static {
       try{
           System.loadLibrary("gnustl_shared");
           //To do - add your static code
       }
       catch(UnsatisfiedLinkError e) {
            Log.v(TAG, "Native code library failed to load.\n" + e);
       }         
       catch(Exception e) {
            Log.v(TAG, "Exception: " + e);
       }
   }

That's it! it solved my problem... Hope it helped.

Inbal

这篇关于Unforunately OpenCV的经理已经停止OpenCV的2.4.3适用于Android 4.2(Mac OSX版10.7)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆