Compiling CUDA examples gives a build error

I am running Windows 7 64bit with Visual Studio 2008. I have installed the CUDA and SDK drivers. The SDK comes with several examples, including compiled executables and source code. Compiled executables work wonderfully. When I open the vc90 solutions and proceed to create a Win32 configuration, I get this error:

Error   1   fatal error LNK1181: cannot open input file '.\Release\bandwidthTest.cu.obj'    bandwidthTest   bandwidthTest

Build Log:

1>------ Build started: Project: bandwidthTest, Configuration: Release Win32 ------
1>Compiling with CUDA Build Rule...
1>"C:\CUDA\bin64\nvcc.exe"    -arch sm_10 -ccbin "c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin"    -Xcompiler "/EHsc /W3 /nologo /O2 /Zi   /MT  " -I"C:\CUDA\include" -I"../../common/inc" -maxrregcount=32  --compile -o "Release\bandwidthTest.cu.obj" "c:\ProgramData\NVIDIA Corporation\NVIDIA GPU Computing SDK\C\src\bandwidthTest\bandwidthTest.cu" 
1>nvcc fatal   : Visual Studio configuration file '(null)' could not be found for installation at 'c:/Program Files (x86)/Microsoft Visual Studio 9.0/VC/bin/../..'
1>Linking...
1>LINK : fatal error LNK1181: cannot open input file '.\Release\bandwidthTest.cu.obj'
1>Build log was saved at "file://c:\ProgramData\NVIDIA Corporation\NVIDIA GPU Computing SDK\C\src\bandwidthTest\Release\BuildLog.htm"
1>bandwidthTest - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

If I try to compile on x64, it doesn't build at all and just skips the project

1>------ Skipped Build: Project: bandwidthTest ------
1> 
========== Build: 0 succeeded or up-to-date, 0 failed, 1 skipped ==========

I am new to C ++, doing C # for a while. I am sure there is something small that I am missing, but any tips you could give would be appreciated.

+5
source share
3 answers

, x64. x64. 32- cuda 64- win7.

, 64- .

+2

.

.obj , nvcc.

nvcc fatal   : Visual Studio configuration file '(null)' could not be found for installation at 'c:/Program Files (x86)/Microsoft Visual Studio 9.0/VC/bin/../..'
+2

, . , 64- Visual Studio, 64- CUDA.

32- Visual Studio, 32- CUDA. 64- . 64-, 32- (-) .

+1

All Articles