make -j4 fails when installing openCV for ubuntu 16.04
When make -j4 it ended up fails like this:
[ 86%] Linking CXX executable ../../bin/opencv_perf_stitching
[ 87%] Built target opencv_test_stitching
[ 87%] Generating pyopencv_generated_include.h, pyopencv_generated_funcs.h, pyopencv_generated_types.h, pyopencv_generated_type_reg.h, pyopencv_generated_ns_reg.h
/bin/sh: 1: /home/jbd/.virtualenv/OCR/bin/python: not found
modules/python2/CMakeFiles/opencv_python2.dir/build.make:325: recipe for target 'modules/python2/pyopencv_generated_include.h' failed
make[2]: * [modules/python2/pyopencv_generated_include.h] Error 127
CMakeFiles/Makefile2:21825: recipe for target 'modules/python2/CMakeFiles/opencv_python2.dir/all' failed
make[1]: * [modules/python2/CMakeFiles/opencv_python2.dir/all] Error 2
make[1]: * Waiting for unfinished jobs....
[ 87%] Built target opencv_perf_stitching
Makefile:160: recipe for target 'all' failed
make: * [all] Error 2
I've searched everywhere for 2 weeks for the solution but none of them are any help, is there any solution?
/home/jbd/.virtualenv/OCR/bin/python
-- probably no snake living there.what did you pass to cmake for the python params ?
cmake -D CMAKE_BUILD_TYPE=RELEASE \ -D CMAKE_INSTALL_PREFIX=/usr/local \ -D INSTALL_C_EXAMPLES=ON \ -D INSTALL_PYTHON_EXAMPLES=ON \ -D WITH_TBB=ON \ -D WITH_V4L=ON \ -D WITH_QT=ON \ -D WITH_OPENGL=ON \ -D OPENCV_EXTRA_MODULES_PATH=../../opencv_contrib/modules \ -D BUILD_EXAMPLES=ON .. something like this...