Install CUDAtoolkit and SDK

1. Install g++ and some dev stuff
#apt-get install g++ (I needed it for compiling the SDK examples)
#apt-get install mesa-common-dev libgl1-mesa-dev libglu1-mesa-dev libxi-dev libxmu-dev glutg3-dev libglut-dev (for SDK)
(完全不知道第二個安裝的是什麼,nvidia cuda 安裝說明也沒有寫,但是debian的光碟有這些)


2. Install the cudatoolkit(default install paht [/usr/src],auto make dir cuda)
#sh cudatoolkit_3.0_linux_64_ubuntu9.04.run

3.add path for cudatookit
#export PATH=/usr/local/cuda/bin:$PATH
#export LD_LIBRARY_PATH=/usr/local/cuda/lib:$LD_LIBRARY_PATH (for 64-bit: export

LD_LIBRARY_PATH=/usr/local/cuda/lib64:$LD_LIBRARY_PATH)
or add in user .brashrc file
#source ~/.brashrc

4.check
#nvcc --version

install cudatookit END

5.intsall SDK
#sh gpucomputingsdk3.0_linux.run(default [/home/USER/NVIDIA_GPU_Computing_SDK])

6. Go to /home/USER/NVIDIA_GPU_Computing_SDK/C and run 'make'
#cd USER/NVIDIA_GPU_Computing_SDK/C
#make
(some warnings will be shown, but the examples will run
After the compilation you find the binarys in [/home/USER/NVIDIA_GPU_Computing_SDK/C/bin])

7.source code in /home/USER/NVIDIA_GPU_Computing_SDK/C/src
END

備註:
此文章參考 NVIDIA forums
作者為:Lucas
版塊:CUDA in linux

沒有留言:

張貼留言