Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Unable to compile OpenCV with CUDA9 and gcc6

My system: CUDA 9.0 cudnn 7.1 gcc6/g++6

Encounter the following error: ``` CMake Error at cuda_compile_generated_gpu_mat.cu.o.cmake:206 (message): Error generating /home/yxchng/git/release/opencv-3.3.1/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda/./cuda_compile_generated_gpu_mat.cu.o

```

Cmake command:

cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=/usr/bin/gcc-6 -DCMAKE_CXX_COMPILER=/usr/bin/g++-6 -DBUILD_opencv_python2=ON -DBUILD_opencv_python3=ON -DWITH_CUDA=YES -DWITH_CUBLAS=YES -DCUDA_GENERATION=Pascal -DWITH_IPP=OFF -DCMAKE_INSTALL_PREFIX=install -DWITH_GSTREAMER=OFF -DCUDA_NVCC_FLAGS="-ccbin /opt/cuda/bin/gcc-6" ..