Back to Cuda
June 29th, 2011 by Melaneum
After one year without doing much with cuda (since this), I’m back!
Last time, I had some problems with gcc 4.4 not being supported, I had to downgrade to 4.3. Sure enough, similar problem this time when trying to compile the SDK:
/usr/local/cuda/include/host_config.h:82:2: error: #error -- unsupported GNU version! gcc 4.5 and up are not supported!
This time, my standard gcc is 4.6… we are two versions back now.
The fix is simple: edit the common.mk files to have
CXX := g++-4.4 -fPIC CC := gcc-4.4 -fPIC LINK := g++-4.4 -fPIC NVCCFLAGS := --compiler-bindir /usr/bin/gcc-4.4
(note that there are two common.mk to compile the whole SDK).
This entry was posted on Wednesday, June 29th, 2011 at 05:10 UTC and is filed under Cuda. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.
February 1st, 2012 at 11:17 UTC
Excellent!
Thanks for the tip! It works perfectly with 4.1.28 on oneiric 11.10.
February 1st, 2012 at 11:28 UTC
[...] CUDALibraries/common and C/common. After wasting a lot of time finally found the source for the fix here and [...]