Monday, February 24, 2014

CUDA Compiler Error in Visual Studio 2012 Error MSB3721: The command "C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.5\bin\nvcc.exe"

I am very new to CUDA and parallel programming.  I was getting all kinds of errors in the beginning due wrong DLL,  LIB folder, Working directory etc.  However, the following error message was little confusing and misleading:

C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V110\BuildCustomizations\CUDA 5.5.targets(592,9): error MSB3721: The command ""C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.5\bin\nvcc.exe" -gencode=arch=compute_10,code=\"sm_10,compute_10\" --use-local-env --cl-version 2012 -ccbin "C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin"  -IC:\OpenCV -IC:\OpenCV\build -IC:\OpenCV\build\include -IC:\OpenCV\build\include\opencv -IC:\OpenCV\build\x86 -IC:\OpenCV\build\x86\vc10 -IC:\OpenCV\build\x86\vc10\bin -IC:\OpenCV\build\x86\vc10\lib -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.5\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.5\include"  -G   --keep-dir Debug -maxrregcount=0  --machine 32 --compile -cudart static  -g   -DWIN32 -D_DEBUG -D_CONSOLE -D_MBCS -Xcompiler "/EHsc /W3 /nologo /Od /Zi /RTC1 /MDd  " -o Debug\kernel.cu.obj "D:\Santhosh\Project\Cuda1-OLD\Cuda1\kernel.cu"" exited with code 2.

I found a lot of recommendation on the net about changing the compute type, hardware configuration  etc for resolving this issue.  In my case, I was missing the correct folder name in the Include Directories under VC++ Directories node.  Everything started working after I added the correct include directories. 

image

1 comments:

Great Article
Cyber Security Projects

projects for cse

Networking Projects

JavaScript Training in Chennai

JavaScript Training in Chennai

The Angular Training covers a wide range of topics including Components, Angular Directives, Angular Services, Pipes, security fundamentals, Routing, and Angular programmability. The new Angular TRaining will lay the foundation you need to specialise in Single Page Application developer. Angular Training

Post a Comment

Popular Posts

Share

Twitter Delicious Facebook Digg Stumbleupon Favorites More