Android NDK:错误:src / main / jni / Android.mk:opencv_java:LOCAL_SRC_FILES指向丢失的文件

时间:2017-02-26 05:05:34

标签: android opencv android-ndk

include $(CLEAR_VARS)

#opencv
OPENCVROOT := C:\OpenCV-2.4.9-android-sdk
OPENCV_CAMERA_MODULES :=on
OPENCV_INSTALL_MODULES:=on
OPENCV_LIB_TYPE:=SHARED
include $(OPENCVROOT)/sdk/native/jni/OpenCV.mk

LOCAL_SRC_FILES := com_example_aamirhussain_ndkopencvtest1_OpencvNativeClass.cpp
LOCAL_LDLIBS += -llog
LOCAL_MODULE := MyOpencvLibs

include $(BUILD_SHARED_LIBRARY)


Android NDK: ERROR:src/main/jni/Android.mk:opencv_java: LOCAL_SRC_FILES    points to a missing file    
我检查.cpp文件路径也是正确的。但无法弄清楚实际问题在哪里。

1 个答案:

答案 0 :(得分:2)

假设cpp确实位于正确的位置,请在Android.mk文件的开头添加,因为根据文档需要:

indexOf

有关详细说明,请参阅此处:Android.mk,在“基本”部分。