Ask Your Question
1

Error While installing OpenCV 3.4.2

asked 2018-07-29 07:31:54 -0600

vickey97 gravatar image

Please Someone Help Me! I wanted to install OpenCV on my RaspberryPi 3 with Raspbian Stretch installed. i'm a beginner here so i used this site to learn and install OpenCV. "https://www.pyimagesearch.com/2017/09..."

When I try the compiling command MAKE, it starts but at around 51% it stops and gives me this error.

CMakeFiles/opencv_perf_core.dir/perf/opencl/perf_matop.cpp.o: file not recognized: File truncated collect2: error: ld returned 1 exit status modules/core/CMakeFiles/opencv_perf_core.dir/build.make:881: recipe for target 'bin/opencv_perf_core' failed make[2]: * [bin/opencv_perf_core] Error 1 CMakeFiles/Makefile2:2696: recipe for target 'modules/core/CMakeFiles/opencv_perf_core.dir/all' failed make[1]: [modules/core/CMakeFiles/opencv_perf_core.dir/all] Error 2 make[1]: Waiting for unfinished jobs.... CMakeFiles/opencv_test_imgproc.dir/test/ocl/test_blend.cpp.o: file not recognized: File truncated collect2: error: ld returned 1 exit status modules/imgproc/CMakeFiles/opencv_test_imgproc.dir/build.make:1401: recipe for target 'bin/opencv_test_imgproc' failed make[2]: [bin/opencv_test_imgproc] Error 1 CMakeFiles/Makefile2:3271: recipe for target 'modules/imgproc/CMakeFiles/opencv_test_imgproc.dir/all' failed make[1]: [modules/imgproc/CMakeFiles/opencv_test_imgproc.dir/all] Error 2 [ 51%] Built target opencv_test_objdetect CMakeFiles/opencv_perf_imgproc.dir/perf/perf_resize.cpp.o: file not recognized: File truncated collect2: error: ld returned 1 exit status modules/imgproc/CMakeFiles/opencv_perf_imgproc.dir/build.make:1063: recipe for target 'bin/opencv_perf_imgproc' failed make[2]: [bin/opencv_perf_imgproc] Error 1 CMakeFiles/Makefile2:3347: recipe for target 'modules/imgproc/CMakeFiles/opencv_perf_imgproc.dir/all' failed make[1]: [modules/imgproc/CMakeFiles/opencv_perf_imgproc.dir/all] Error 2 Makefile:160: recipe for target 'all' failed make: * [all] Error 2

Please Help me what should i do? i'm tryind to install OpenCV 3.4.2 with python 3.

edit retag flag offensive close merge delete

Comments

file not recognized: File truncated Check your SD card?

LBerger gravatar imageLBerger ( 2018-07-29 17:16:14 -0600 )edit

Yup! I literally tried 4 times and I can open GUI with VNC but installations gets stuck at 51% giving this error. And green light flashes up at that moment So i guess SD Card is okay.

vickey97 gravatar imagevickey97 ( 2018-07-30 06:17:26 -0600 )edit

2 answers

Sort by ยป oldest newest most voted
0

answered 2018-07-30 12:48:17 -0600

edit flag offensive delete link more
0

answered 2018-07-29 23:54:23 -0600

jarulsamy gravatar image

Instead of compiling from source, why not install with pip?

pip install opencv-python

If pip isn't installed: sudo apt-get install python-pip

edit flag offensive delete link more

Comments

Okay. so if i install with this pip command it will install opencv, right?

vickey97 gravatar imagevickey97 ( 2018-07-30 06:11:01 -0600 )edit

Yes @vickey97. Pip is pythons native package manager. https://en.wikipedia.org/wiki/Pip_(pa...

jarulsamy gravatar imagejarulsamy ( 2018-07-31 21:57:04 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2018-07-29 07:31:54 -0600

Seen: 2,651 times

Last updated: Jul 29 '18