Reputation: 31
When trying to build an example from the NVIDIA GPU Computing SDK using Visual Studio 2008, I get this weird error:
"C:\CUDA\bin\nvcc.exe" -arch sm_10 -ccbin "C:\Program Files\Microsoft Visual Studio 9.0\VC\bin" -deviceemu -D_DEVICEEMU -Xcompiler "/EHsc /W3 /nologo /Od /Zi /MTd " -I"C:\CUDA\include" -I"../../common/inc" -maxrregcount=32 --compile -o "Debug\matrixMul.cu.obj" "c:\Documents and Settings\All Users.SYSROOT\Application Data\NVIDIA Corporation\NVIDIA GPU Computing SDK\C\src\matrixMul\matrixMul.cu"
nvcc fatal : Could not open input file C:\DOCUME~1\Murali_Krishna05\Local Settings\Temp/tmpxft_000008cc_00000000-1
Upvotes: 2
Views: 1228
Reputation: 1401
This is a known old bug in the NVIDIA VS2008 integration. We've had to do all of the following 3 steps to solve it.
set TEMP=%SystemRoot%\TEMP
set PATH=
to avoid any quotation marks "
which are anyway superfluous (and dangerous!). Just delete them: individual directories are separated by semicolon ;
and spaces are not a problem(
and )
in "C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\amd64\vcvarsamd64.bat"
and "C:\Program Files (x86)\Microsoft Visual Studio 9.0\Common7\Tools\vsvars32.bat"
Example for step 3:
Replace
@if not "%WindowsSdkDir%" == "" (
set "PATH=%WindowsSdkDir%bin;%PATH%"
set "INCLUDE=%WindowsSdkDir%include;%INCLUDE%"
set "LIB=%WindowsSdkDir%lib;%LIB%"
)
by
@if "%WindowsSdkDir%" == "" @goto :SKIP_SET_SDK
set "PATH=%WindowsSdkDir%bin;%PATH%"
set "INCLUDE=%WindowsSdkDir%include;%INCLUDE%"
set "LIB=%WindowsSdkDir%lib;%LIB%"
:SKIP_SET_SDK
Upvotes: 0
Reputation: 31
I solved it by replacing the environmental varialble "TEMP=%USERPROFILE%\Local Settings\Temp" by "TEMP=%SystemRoot%\TEMP".
Upvotes: 1