Thank you very much Andreas.

I figured this out a couple of weeks ago and indeed specifying CXX=g++44
worked.  Specifically, the following works for RHEL 5.5:

$ python setup.py --cuda_root=/usr/local/cuda  \
--cudadrv_lib_dir={driver dir here}
$ CC=gcc44 CXX=g++44 make install

I tried to post this information to the list but my top posting was
prevented.

Patrick

On 1/30/11 5:25 PM, Andreas Kloeckner wrote:
> Hi Patrick,
> 
> On Fri, 7 Jan 2011 20:27:51 +0000 (UTC), Patrick Herron <patric...@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@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
>> installed. 
>>
>> Error:
>>
>> [root@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
>>   File
>> "/usr/lib64/python2.4/site-packages/pycuda-0.94.2-py2.4-linux-x86_64.egg/
>> pycuda/tools.py",
>> line 30, in ?
>>     import pycuda.driver as cuda
>>   File
>> "/usr/lib64/python2.4/site-packages/pycuda-0.94.2-py2.4-linux-x86_64.egg/
>> pycuda/driver.py",
>> line 1, in ?
>>     from pycuda._driver import *
>> ImportError:
>> /usr/lib64/python2.4/site-packages/pycuda-0.94.2-py2.4-linux-x86_64.egg/
>> pycuda/_driver.so:
>> 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
> std::ctype<char>::_M_widen_init() const
> 
> which is specified in 22.4.1.1 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
> 
> HTH,
> Andreas

-- 
Patrick Herron
Research Analyst & Technologist
Kimberly J. Jenkins Chair for New Technologies in Society
Duke University
patric...@duke.edu     919-668-0276
Smith Warehouse, Bay 11, Room A232, Box 90766

Center for Nanotechnology in Society
    http://www.cns.ucsb.edu/research/irg4
Jenkins Collaboratory
    http://www.jhfc.duke.edu/jenkins/patrick.php
Virtual Peace
    http://virtualpeace.org/



_______________________________________________
PyCUDA mailing list
PyCUDA@tiker.net
http://lists.tiker.net/listinfo/pycuda

Reply via email to