Majid Azimi
Majid Azimi

Reputation: 1017

error in installing opencv with CUDA - opencv_cudaarithm Error

Is there somebody who knows how to solve this problem: having already done cmaking using ccmake.., in making step using make -j7 got this error:

Linking CXX shared library ../../lib/libopencv_cudaarithm.so
[ 38%] Built target opencv_cudaarithm
make: *** [all] Error 2

appreciate it if you could help me out! I used the cmake below:

CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/home/<user>/opencv 
-D PYTHON_EXECUTABLE=/home/<user>/anaconda/bin/python2.7 
-D PYTHON_INCLUDE_DIR=/home/<user>/anaconda/include/python2.7 
-D PYTHON_INCLUDE_DIRS=/home/<user>/anaconda/include/python2.7 
-D PYTHON_INCLUDE_DIR2=/home/<user>/anaconda/include/python2.7 
-D PYTHON_LIBRARIES=/home/<user>/anaconda/lib/libpython2.7.so 
-D PYTHON_LIBRARY=/home/<user>/anaconda/lib/libpython2.7.so 
-D PYTHON_PACKAGES_PATH=/home/<user>/anaconda/lib/python2.7/site-packages -D BUILD_EXAMPLES=ON -D BUILD_NEW_PYTHON_SUPPORT=ON 
-D PYTHON2_LIBRARY=/home/<user>/anaconda/lib/libpython2.7.so 
-D PYTHON_NUMPY_INCLUDE_DIRS=/home/<user>/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy -D BUILD_opencv_python3=OFF 
-D BUILD_opencv_python2=ON -D INSTALL_C_EXAMPLES=ON 
-D INSTALL_PYTHON_EXAMPLES=ON -D WITH_TBB=ON -D WITH_V4L=ON 
-D WITH_OPENGL=ON -D WITH_CUBLAS=ON -D WITH_GTK=ON 
-D MATLAB_INCLUDE_DIRS=/home/<user>/MATLAB/extern/include 
-D MATLAB_LIBRARY_DIRS=/home/<user>/MATLAB/bin 
-D MATLAB_MEX_SCRIPT=/home/<user>/MATLAB/bin 
-D MATLAB_ROOT_DIR=/home/<user>/MATLAB ..

Upvotes: 0

Views: 3027

Answers (2)

Majid Azimi
Majid Azimi

Reputation: 1017

I found the problem and its solution. Becuase my OS is 64 bit, I should've used a different configuration for the ffmpeg and x264 installations. I used the guidance in the following link and managed to install Opencv without any more problems.

http://www.ozbotz.org/opencv-installation/

Upvotes: 1

AlexYang
AlexYang

Reputation: 16

One thing I usually check is the makefile that cmake generated. Another thing to check is the CMakeCache file. Check if the directories are been correctly set.

Upvotes: 0

Related Questions