从源代码编译opencv_3.4.0时出错

时间:2018-04-30 05:18:29

标签: cmake opencv3.0 cmake-gui

尝试从源代码生成opencv-3.4.0时遇到以下错误:

main:StaticLib theo$ make -j8
[  0%] Built target gen-pkgconfig
[  1%] Built target ittnotify
[  3%] Built target zlib
[  5%] Built target gen_opencv_python_source
[  8%] Built target libjpeg
[ 14%] Built target ippiw
[ 15%] Built target libjasper
[ 17%] Built target libpng
[ 23%] Built target libtiff
[ 30%] Built target libprotobuf
[ 38%] Built target IlmImf
[ 45%] Built target opencv_core
[ 46%] Built target opencv_flann
[ 48%] Built target opencv_ml
[ 56%] Built target opencv_imgproc
[ 57%] Built target opencv_objdetect
[ 59%] Built target opencv_video
[ 60%] Built target opencv_photo
[ 68%] Built target opencv_dnn
[ 68%] Built target opencv_shape
[ 70%] Built target opencv_imgcodecs
[ 70%] Built target opencv_videoio
[ 70%] Built target opencv_highgui
[ 71%] Built target opencv_superres
[ 71%] Linking CXX executable ../../bin/opencv_version
[ 71%] Linking CXX executable ../../bin/opencv_annotation
[ 71%] Linking CXX executable ../../bin/opencv_visualisation
ld: library not found for -lgstbase-1.0
clang: error: linker command failed with exit code 1 (use -v to see invocation)
ld: library not found for -lgstbase-1.0
ld: library not found for -lgstbase-1.0
clang: error: linker command failed with exit code 1 (use -v to see invocation)
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [bin/opencv_visualisation] Error 1
make[1]: *** [apps/visualisation/CMakeFiles/opencv_visualisation.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
make[2]: *** [bin/opencv_version] Error 1
make[2]: *** [bin/opencv_annotation] Error 1
make[1]: *** [apps/annotation/CMakeFiles/opencv_annotation.dir/all] Error 2
make[1]: *** [apps/version/CMakeFiles/opencv_version.dir/all] Error 2
[ 72%] Built target opencv_ts
[ 74%] Built target opencv_features2d
make: *** [all] Error 2

我找不到包lgstbase-1.0,我不知道如何将它链接到项目。

我在lintl遇到了同样的错误,但我按照另一个线程的建议修复它(brew重新安装gettext)。

有什么想法吗?

0 个答案:

没有答案