I am a newcomer to CUDA and have been trying to get CUDA to work on Ubuntu 8.10. Today I finally managed to figure out how to make it work and would like to share these tips with other newbies like me. These should be viewed as additional tips on top of other Ubuntu-related tips you get elsewhere. So I will assume that you have read the many guides you can get by googling and have installed all the necessary dependencies.
i) Ensure that you have the nvidia hardware drivers installed. You should not need the drivers provided by NVIDIA.
ii) Download the Red Hat version of the Toolkit version 2.0. The newest 2.1 Beta which is the only version appearing when you click Ubuntu 8.04 does NOT work. Then proceed to install using root privileges. Use the latest version of gcc that is compatible with your kernel. In my case, it is gcc 4.3 with a fully-updated Ubuntu system. This can be done by ensuring that /usr/bin/gcc links to gcc4.3 and not others.
iii) If you haven’t already done so, install gcc 4.2 and the equivalent versions of g++ etc. Then switch your default compiler to gcc 4.2 by changing the symbolic link in /usr/bin/gcc.
iv) Download the Ubuntu 2.1 Beta versions of the SDK and install it using normal privileges. I couldn’t get the 2.0 versions to work. They keep giving me compiler error after compiler error. 2.1 Beta compiles with lots of warnings, but it finishes. Goto to the bin and try fluidsGL. If it works, you are home free.
Hope this helps. (I am holding out a hope that someone can compile all this into a proper deb and spare many people many hours of fiddling).