ok we are making progress after some more coffee one of the problems disappeared after I modified the generated config file by hand.
[b]fry:pycuda.git wohlgemuth$ cat siteconf.py
BOOST_INC_DIR = ['/usr/local/boost/include/boost-1_35']
BOOST_LIB_DIR = ['/usr/local/boost/lib']
BOOST_PYTHON_LIBNAME = ['boost_python-mt-1_35']
CUDA_ROOT = '/usr/local/cuda/'
CUDADRV_LIB_DIR = ['/usr/local/cuda/lib']
CUDADRV_LIBNAME = ['cuda']
CXXFLAGS = 
LDFLAGS = 
Now I was able to compile pycuda, but sadly the quest is not done yet and it complain with a couple of warnings.
gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-madd -fno-common -dynamic -Wall -O3 -DNDEBUG -arch i386 -arch ppc -pipe -I/usr/local/boost/include/boost-1_35 -I/usr/local/cuda/include -I/Library/Python/2.5/site-packages/numpy-1.1.0-py2.5-macosx-10.5-i386.egg/numpy/core/include -I/System/Library/Frameworks/Python.framework/Versions/2.5/include/python2.5 -c src/wrapper/wrap_cudadrv.cpp -o build/temp.macosx-10.5-i386-2.5/src/wrapper/wrap_cudadrv.o
g++ -Wl,-F. -bundle -undefined dynamic_lookup -arch i386 -arch ppc build/temp.macosx-10.5-i386-2.5/src/wrapper/wrap_cudadrv.o -L/usr/local/boost/lib -L/usr/local/cuda/lib -lboost_python-mt-1_35 -lcuda -o build/lib.macosx-10.5-i386-2.5/pycuda/_driver.so
ld: warning in /usr/local/boost/lib/libboost_python-mt-1_35.dylib, file is not of required architecture
ld: warning in /usr/local/cuda/lib/libcuda.dylib, file is not of required architecture
I guess it’s related to the flag “-arch i386” or “-arch ppc”. I try to track it down.
if we ignore this warning we will not be able to run the tests
[b]fry:test wohlgemuth$ python test_driver.py
Traceback (most recent call last):
File "test_driver.py", line 2, in <module>
import pycuda.driver as drv
File "/Library/Python/2.5/site-packages/pycuda-0.90.2-py2.5-macosx-10.5-i386.egg/pycuda/driver.py", line 1, in <module>
from _driver import *
ImportError: dlopen(/Library/Python/2.5/site-packages/pycuda-0.90.2-py2.5-macosx-10.5-i386.egg/pycuda/_driver.so, 2): Symbol not found: _cuCtxGetDevice
Referenced from: /Library/Python/2.5/site-packages/pycuda-0.90.2-py2.5-macosx-10.5-i386.egg/pycuda/_driver.so
Expected in: dynamic lookup