Please refer to NVIDIA's CUDA website to confirm your video card is CUDA ready. You can also check it here.
1. Unless you have the proprietary NVIDIA Drivers already installed, download the appropriate Developer Drivers from here. Click on "Get Latest CUDA Toolkit".
2. Install the drivers as root. If you've installed Proprietary NVIDIA drivers before, the process is the same (for Linux).
Linux:
//**********
- Ctrl-Alt-F2
- Log in as root (as yourself on Ubuntu)
- Stop your window manager: telinit 3 usually does it. For Ubuntu, try sudo service gdm stop (this assumes your running GNOME).
- Become root (if not already) or utilize sudo for Ubuntu
- Navigate to the directory where you've downloaded the NVIDIA graphic drivers
- Run sh dev_driver_name.run. Try sudo sh dev_driver_name.run
//**********
- Run devdriver.dmg
3. Download and install CUDA Toolkit.
Linux:
//**********
shell$ cd Downloads
shell$ sh cudatoolkit.run
For "enter install path", I used my home directory: /home/myname. You may utilize default path if needed.
//**********
OS X:
//**********
- Run cudatoolkit.pkg
4. Update your PATH and LD_LIBRARY_PATH:
Linux:
//**********
PATH - /Path/To/Your/CUDA/Install/bin (my version --> /home/myname/cuda/bin)
LD - /Path/To/Your/CUDA/Install/lib (my version --> /home/myname/cuda/lib64:/home/myname/cuda/lib)
//**********
OS X:
//**********
PATH - /usr/local/cuda/bin
DYLD - /usr/local/cuda/lib
//**********
5. Download and install GPU Computing SDK
Linux:
//**********
shell$ cd Downloads
shell$ sh gpucomputingsdk.run
For "enter install path", I accepted the default. This is dependent upon where your CUDA Toolkit is installed. Additionally, you will be asked to confirm your CUDA installation directory.
//**********
OS X:
//**********
- Run gpucomputingsdk.pkg
6. Make the example programs.
Linux:
//**********
shell$ cd NVIDIA_GPU_Computing_SDK
shell$ cd C
shell$ make
//**********
OS X:
//**********
shell$ cd /Developer/GPU\ Computing/C
shell$ make
//**********
You have a fully functional CUDA environment. Run a few of the example programs to test your environment. Good luck!