build with CUDA 5.0 on macosx (Bug #2844)


Added by Boris Mansencal over 4 years ago. Updated about 2 years ago.


Status:Open Start date:2013-02-28
Priority:Normal Due date:
Assignee:- % Done:

0%

Category:gpu (cuda)
Target version:-
Affected version:branch 'master' (2.4.9) Operating System:
Difficulty: HW Platform:
Pull request:

Description

I am trying to build current head version of OpenCV (02/28/2013) on a 2008 MacBook Pro with CUDA 5.0 enabled.

The configuration is :
Mac Book Pro 15" (end 2008) with Intel Core 2 Duo 2.53GHz
Mac OS X 10.7.5
clang 4.1
NVIDIA GeForce 9600M GT512MB
CUDA 5.0 (V0.2.1221)

make VERBOSE=1
gives me the following error :

[ 23%] Building NVCC (Device) object modules/core/CMakeFiles/cuda_compile.dir/src/cuda/./cuda_compile_generated_matrix_operations.cu.o
cd /Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda && "/Applications/CMake 2.8-10.app/Contents/bin/cmake" E make_directory /Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda/.
cd /Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda && "/Applications/CMake 2.8-10.app/Contents/bin/cmake" -D verbose:BOOL=1 -D build_configuration:STRING=Release -D generated_file:STRING=/Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda/./cuda_compile_generated_matrix_operations.cu.o -D generated_cubin_file:STRING=/Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda/./cuda_compile_generated_matrix_operations.cu.o.cubin.txt -P /Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda/cuda_compile_generated_matrix_operations.cu.o.cmake
-
Removing /Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda/./cuda_compile_generated_matrix_operations.cu.o
"/Applications/CMake 2.8-10.app/Contents/bin/cmake" E remove /Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda/./cuda_compile_generated_matrix_operations.cu.o
-
Generating dependency file: /Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda/cuda_compile_generated_matrix_operations.cu.o.NVCC-depend
/usr/local/cuda/bin/nvcc -M -D__CUDACC__ /Users/mansencal/tools/opencv_git/modules/core/src/cuda/matrix_operations.cu -o /Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda/cuda_compile_generated_matrix_operations.cu.o NVCC-depend -ccbin /usr/bin/cc -m64 -DHAVE_CVCONFIG_H -DHAVE_ALLOCA -DHAVE_ALLOCA_H -DHAVE_LIBPTHREAD -DHAVE_UNISTD_H -Xcompiler ,\"-O3\",\"-DNDEBUG\" -gencode arch=compute_11,code=sm_11 -gencode arch=compute_12,code=sm_12 -gencode arch=compute_13,code=sm_13 -gencode arch=compute_20,code=sm_20 -gencode arch=compute_20,code=sm_21 -gencode arch=compute_30,code=sm_30 -gencode arch=compute_20,code=compute_20 -gencode arch=compute_30,code=compute_30 -Xcompiler -DCVAPI_EXPORTS -Xcompiler -fPIC -Xcompiler -fno-finite-math-only -DNVCC -I/usr/local/cuda/include -I/Users/mansencal/tools/opencv_git/modules/gpu/include -I/Users/mansencal/tools/opencv_git/build/3rdparty/zlib -I/Users/mansencal/tools/opencv_git/3rdparty/zlib -I/Users/mansencal/tools/opencv_git/build/modules/core -I/Users/mansencal/tools/opencv_git/modules/core/src -I/Users/mansencal/tools/opencv_git/modules/core/include -I/Users/mansencal/tools/opencv_git/build -I/Users/mansencal/tools/tbb41_20130116oss/include -I/Users/mansencal/tools/eigen-3.1.2 -I/usr/local/cuda/include
clang: error: unsupported option '-dumpspecs'
clang: error: no input files
CMake Error at cuda_compile_generated_matrix_operations.cu.o.cmake:206 (message):
Error generating
/Users/mansencal/tools/opencv_git/build/modules/core/CMakeFiles/cuda_compile.dir/src/cuda/./cuda_compile_generated_matrix_operations.cu.o

make2: * [modules/core/CMakeFiles/cuda_compile.dir/src/cuda/./cuda_compile_generated_matrix_operations.cu.o] Error 1
make1:
[modules/core/CMakeFiles/opencv_core.dir/all] Error 2
make: *
* [all] Error 2


History

Updated by Marina Kolpakova over 4 years ago

  • Assignee set to Marina Kolpakova
  • Category set to gpu (cuda)

Updated by Boris Mansencal over 4 years ago

It seems this is the same bug than Bug #2504. So it is not solved.

It is related to the fact that -ccbin /usr/bin/cc is specified and /usr/bin/cc is a link to clang on recent MacOS X versions.
It seems that it is FindCUDA.cmake, available with CMake 2.8.10, that sets CUDA_HOST_COMPILER to /usr/bin/cc.

Updated by Marina Kolpakova over 4 years ago

  • Assignee deleted (Marina Kolpakova)

Updated by Maksim Shabunin about 2 years ago

Issue has been transferred to GitHub: https://github.com/Itseez/opencv/issues/4518

Also available in: Atom PDF