CUDA on Ubuntu 8.10 SDK Compiling error

I recently upgraded to 8.10 version of Ubuntu. Something happened, and I no longer can compile any of the SDK projects. I reinstalled all the drivers and have had no luck:

Hi,

try to switch off -O1 - -O3 optimization. Such a trick helps me to compile my project. I think, there is a bug in gcc 4.3 that is supplied in Ubuntu 8.10.

I tried to reinstall nvcc such a way that it will use old gcc4.2 instead of gcc4.3, but does not succeed.

EDIT: If somebody know how to do it, please, explain it here, then it will be the best solution to this problem.

Sincerely

Ilghiz

I added the #include files that were missing, probably some changes between 8.04 and 8.10, and had to make sure freeglut3-dev was installed. That enabled me to compile about 90% of them, got a few more errors I need to work with to finish it off…

You really need not add an includes to any of the files. The problem with Compiling the SDK on Ubuntu 8.10 resides in the compiler version. The nvcc driver is not integrated with gcc 4.3.2 which is the default compiler installed on ubuntu 8.10. All you need to do is install a 4.1 compiler, and make it the prefered alternative, when working on CUDA apps.

Follow the discussion found inthe thread I opened on the subject - that’s how I found out about it. The relevant quote is:

A simple Copy & Paste of your explicit directions makes CUDA examples finally compile & work on my Debian 64 system.

Thank you for being so clear. I had given up some time ago, now that it works for me, I can go forward. Thanks again.

Yup did the trick for me as well. Thank you very much =) :thumbup:

I installed Ubuntu 8.04 64 bit and followed the instructions here http://lifeofaprogrammergeek.blogspot.com/…-in-ubuntu.html but changed the drivers and everything for ubuntu 8.04 64 bit. When I run make some of the examples compile but when I get to the sobelFilter example I get “/usr/bin/ld: cannot find -lxi”. Am I missing something? I got it to work for all the examples with ubuntu 8.04 32 bit but I need 64 bit since I have 8 GB of memory.

Edit

I ran

sudo apt-get install libxi6 libxi-dev
sudo apt-get install libxmu6 libxmu-dev
sudo apt-get install libc6-dev-i386

and now it works :)