Author Topic: CUDA 6.5 + Code::Blocks using Win 8.1 x64 [PARTIALLY RESOLVED]  (Read 2836 times)

Offline Viperwow

  • Single posting newcomer
  • *
  • Posts: 2
CUDA 6.5 + Code::Blocks using Win 8.1 x64 [PARTIALLY RESOLVED]
« on: February 01, 2015, 12:16:57 pm »
Hello for everyone, and I have few questions..and a little steps that I already did.

I'd found an old post about how to set up CUDA nvcc http://forums.codeblocks.org/index.php/topic,17572.msg120579.html#msg120579 and tried to adapt it for windows version of Code::Blocks, but may be I didn't do it correctly :/

My steps:
1) Download Windows SDK (Somebody said on unknown forum that it contains all libs what I want and cl.exe, but I found no cl.exe :/ bad news for me)
2) Download and install Visual Studio Express 2013 (Cause it exactly has cl.exe)
3) Do all instructions of tutorial from link above..except following steps:
Quote
Under the Search directories tab, add /your_location/NVIDIA_CUDA_SDK2/common/inc to the Compiler box (so that headers like cutil.h will be found).
Add /your_location/NVIDIA_CUDA_SDK2/lib to the Linker box.
Add /your_location/NVIDIA_CUDA_SDK2/common/lib/linux (modify for your OS) to the Linker box.
I'd decided to write something instead of this steps:
Quote
a) C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v6.5\include added to "Compiler" box in "Search directory" tab
b) C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v6.5\lib\Win32 added to "Linker" box in "Search directory" tab
c) C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v6.5\lib\x64 added to "Linker" box in "Search directory" tab (Is it correct to add search directory path for both x64 and Win32?)
4) Add to "Toolchain executables" tab in "Additional Paths" box path to cl.exe as for me it was "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin

Questions:
1) Is somebody succefully using CUDA nvcc compiler on Code::Blocks and can write how to set up it correctly?(or tell where I did a mistake) [RESOLVED]
Answer: Seems, I setted it up using original tutorial for linux and my additions above. CUDA nvcc compile only *.cu files, so just rename it in project and than compile (still tons of warnings and no code highlight, but it works for me)
2) Is somebody know how to choose encoding for "Build log" and "Build Messages"? (Tried Settings->Editor->General Settings->Other settings tab->encoding and no effect :/)
3) Is Windows SDK needed to use CUDA nvcc compiler? [RESOLVED]
Answer: Windows SDK does not needed, cause it has no cl.exe inside.
4) Is it correctly what I wrote instead of what explained in the tutorial from link above? (Cause it's the first time I setted up another compiler)
« Last Edit: February 02, 2015, 11:08:52 pm by Viperwow »