我有Fedora 23 - 32位,我试图安装opencv 3.0.0。 在终端中执行此步骤时:
sudo make
我得到了这个:
...
[ 26%] Built target opencv_hal
[ 32%] Built target opencv_core
[ 33%] Built target opencv_flann
[ 34%] Built target opencv_ml
[ 41%] Built target opencv_imgproc
[ 44%] Built target opencv_photo
[ 45%] Built target opencv_imgcodecs
[ 46%] Built target opencv_video
[ 46%] Linking CXX shared library ../../lib/libopencv_videoio.so
[ 46%] Built target opencv_shape
/lib/libbz2.so.1: error adding symbols: File in wrong format
collect2: error: ld returned 1 exit status
modules/videoio/CMakeFiles/opencv_videoio.dir/build.make:283: recipe for target 'lib/libopencv_videoio.so.3.0.0' failed
make[2]: *** [lib/libopencv_videoio.so.3.0.0] Error 1
CMakeFiles/Makefile2:4279: recipe for target 'modules/videoio/CMakeFiles/opencv_videoio.dir/all' failed
make[1]: *** [modules/videoio/CMakeFiles/opencv_videoio.dir/all] Error 2
Makefile:149: recipe for target 'all' failed
make: *** [all] Error 2
我该怎么办?
答案 0 :(得分:1)
您必须安装bz2库。
yum install bzip2-devel
或在debian中
apt-get install libbz2