Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

android cmake #339

Closed
liupengkd opened this issue Apr 9, 2018 · 1 comment
Closed

android cmake #339

liupengkd opened this issue Apr 9, 2018 · 1 comment

Comments

@liupengkd
Copy link

当cmake -DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK/build/cmake/android.toolchain.cmake -DANDROID_ABI="armeabi-v7a" -DANDROID_ARM_NEON=ON -DANDROID_PLATFORM=android-14 ..
报错:CMake Error at examples/CMakeLists.txt:4 (find_package):
By not providing "FindOpenCV.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "OpenCV", but
CMake did not find one.

Could not find a package configuration file provided by "OpenCV" with any
of the following names:

OpenCVConfig.cmake
opencv-config.cmake

Add the installation prefix of "OpenCV" to CMAKE_PREFIX_PATH or set
"OpenCV_DIR" to a directory containing one of the above files. If "OpenCV"
provides a separate development package or SDK, be sure it has been
installed.
根据网上的方法添加:-DOpenCV_DIR="/home/liupeng/opencv-2.4.13/release
报错:CMake Error at /home/liupeng/opencv-2.4.13/release/OpenCVConfig.cmake:71 (include):
include could not find load file:

/home/liupeng/opencv-2.4.13/release/OpenCVModules_armeabi_v7a.cmake

Call Stack (most recent call first):
examples/CMakeLists.txt:2 (find_package)

CMake Error at /home/liupeng/opencv-2.4.13/release/OpenCVConfig.cmake:71 (include):
include could not find load file:

/home/liupeng/opencv-2.4.13/release/OpenCVModules_armeabi_v7a.cmake

Call Stack (most recent call first):
examples/ssd/CMakeLists.txt:1 (find_package)

@nihui
Copy link
Member

nihui commented Apr 9, 2018

do not uncomment the "add_subdirectory(examples)" in the top CMakeLists.txt when building for android.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants