QT编译Opencv库过程中出现的问题总结

一、人脸识别模块编译出错

出错原因:没有加入opencv_contrib

OpenCV 4.4开始需要提供opencv_contrib

如果不需要人脸识别模块可以进行下列操作

[ 77%] Linking CXX executable ..\..\bin\opencv_test_dnn.exe
jom: E:\1WT\18.OCR\opencv\build-sources-Desktop_Qt_5_12_10_MSVC2017_64bit-Release\Makefile [all] Error 2 

QT编译Opencv库过程中出现的问题总结_第1张图片

QT编译Opencv库过程中出现的问题总结_第2张图片

二、带有例子的opencv编译

编译带有例子的OpenCV,在cmake的配置中把 BUILD_EXAMPLES 项设置为 ON .

[ 84%] Linking CXX executable ..\..\bin\opencv_test_calib3d.exe
[ 84%] Built target opencv_test_video
jom: E:\1WT\18.OCR\opencv\build-sources-Desktop_Qt_5_12_10_MSVC2017_64bit-Release\Makefile [all] Error 2
14:55:26: 进程"E:\1WT\5.software\CMake\bin\cmake.exe"退出,退出代码 2 。
Error while building/deploying project OpenCV (kit: Desktop Qt 5.12.10 MSVC2017 64bit)
The kit Desktop Qt 5.12.10 MSVC2017 64bit has configuration issues which might be the root cause for this problem.

QT编译Opencv库过程中出现的问题总结_第3张图片

QT编译Opencv库过程中出现的问题总结_第4张图片

QT编译Opencv库过程中出现的问题总结_第5张图片

你可能感兴趣的:(qt,opencv,开发语言)