[PyCUDA] Problems compling
lists at informa.tiker.net
Sun Jan 30 14:25:02 PST 2011
On Fri, 7 Jan 2011 20:27:51 +0000 (UTC), Patrick Herron <patrick.h at duke.edu> wrote:
> I too am very eager to use PyCUDA. After some effort I was finally able to
> install on my RHEL5.5 system using
> [root at netreg-536608 doc]# CC=gcc44 make install
> This solved a host of build errors. Your advice on this and other forums has
> been very helpful.
> Unfortunately when I run the test code I get a very similar error to the one
> described above. Further, when I use the above nm command I get empty output,
> which you suggest means I don't have 3.2 drivers. Yet I (only) have 3.2 drivers
> [root at netreg-536608 test]# python test_driver.py
> Traceback (most recent call last):
> File "test_driver.py", line 4, in ?
> from pycuda.tools import mark_cuda_test
> line 30, in ?
> import pycuda.driver as cuda
> line 1, in ?
> from pycuda._driver import *
> undefined symbol: _ZNKSt5ctypeIcE13_M_widen_initEv
Sorry for the delay in replying. The root cause of this seems to be that
PyCUDA picks up a different version of the C++ standard library than the
version it was compiled for. (If I had to guess, it's using the previous
gcc's version instead of the one for gcc.)
The symbol itself demangles to
$ c++filt _ZNKSt5ctypeIcE13_M_widen_initEv
which is specified in 126.96.36.199 of the draft C++0x standard.
A possible fix would be to run setup.py with the environment variable
CXX set to g++44, like this
$ CXX=g++44 python setup.py install
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: not available
More information about the PyCUDA