0

While installing opencv_contrib (during make -j5 step), my laptop went to sleep and gave errors on the install, failing with a fatal error. Retrying make -j5 gave the same error again. trying to uninstall opencv completely using make uninstall also completely fails with a fatal error.

How do I do a fresh install of OpenCV from here?

Error on running make uninstall:

-- Uninstalling "/usr/local/include/opencv2/cvconfig.h"
CMake Error at cmake_uninstall.cmake:20 (MESSAGE):
  Problem when removing "/usr/local/include/opencv2/cvconfig.h"


CMakeFiles/uninstall.dir/build.make:57: recipe for target 
'CMakeFiles/uninstall' failed
make[3]: *** [CMakeFiles/uninstall] Error 1
CMakeFiles/Makefile2:296: recipe for target 
'CMakeFiles/uninstall.dir/all' failed
make[2]: *** [CMakeFiles/uninstall.dir/all] Error 2
CMakeFiles/Makefile2:303: recipe for target             
'CMakeFiles/uninstall.dir/rule' failed
make[1]: *** [CMakeFiles/uninstall.dir/rule] Error 2
Makefile:234: recipe for target 'uninstall' failed
make: *** [uninstall] Error 2
Alkove
  • 25
  • 7

2 Answers2

2

You should try make clean and try to uninstall again. Also you should restart from previous steps for opencv installing

onur aslan
  • 283
  • 3
  • 8
  • I screwed up, I forgot to uninstall before deleting all files in the folder to do a fresh download and install. I'm getting more errors now. `CMake Error: The following variables are used in this project, but they are set to NOTFOUND. Please set them or make sure they are set and tested correctly in the CMake files: ` – Alkove Oct 23 '17 at 16:09
  • It shows this error for headings, `CUDA_CUDA_LIBRARY (ADVANCED)` and `CUDA_nppi_LIBRARY (ADVANCED)`, with a lot of files listed under each of these – Alkove Oct 23 '17 at 16:18
  • I realise this is a completely different problem, so I'll move this to a new thread unless I find a solution elsewhere. – Alkove Oct 23 '17 at 16:30
2

You can't directly delete files from usr/local/...etc so you try giving sudo make uninstall it will work fine!

Ajaykumar
  • 21
  • 1