How to use opencv static library

I am trying to integrate OpenCV into my Android project (using ndk). When I did: OPENCV_LIB_TYPE:=static I cannot build the project, I had this error:

 E:\android-ndk-r8\ndk-build.cmd all Android NDK: Trying to define local module 'opencv_contrib' in jni/Android.mk. E:/android-ndk-r8/build/core/build-module.mk:34: *** Android NDK: Aborting. . Stop. Android NDK: But this module was already defined by jni/Android.mk. 

Any idea how I can solve it? I am using android-ndk-r8 and OpenCV2.4.3

0
source share
1 answer

I am trying to create two native libs based on OpenCV using one Android.mk . This known issue has been fixed in OpenCV 2.4.4 . I need to update the OpenCV4Android SDK or add the line OPENCV_INSTALL_MODULES:=off before the second opencv.mk turned on if I want to use this version.

0
source

Source: https://habr.com/ru/post/1442789/


All Articles