Hi there, my name is Krunal and I'm a new user to PyCUDA. I'm helping Nicolas out on his research. My first order of business was to get PyCUDA installed on my iMac Snow Leopard. Here were my experiences:
1) stick with the version of python installed by Mac, don't upgrade to the latest. The default version is 2.6.1. The main reason for this is because I couldn't figure out how to run a newly upgraded version of python in 32-bit mode. 2) I tried 1.38-1.41 versions of Boost. At the end, the one that worked for me was 1.39. Here is how I got things working: 1) first follow: http://wiki.tiker.net/BoostInstallationHowto but do this: ./bootstrap.sh --prefix=$HOME/pool --libdir=$HOME/pool/lib --with-libraries=signals,thread,python ./bjam address-model=32_64 architecture=x86 variant=release link=shared install (the architecture stuff comes from http://old.nabble.com/Boost-on-Snow-Leopard-failing-to-build-32-bit-target-td25218466.html and is the key to not getting the architecture is invalid when running test_driver.py) 2) then follow: http://wiki.tiker.net/PyCuda/Installation/Mac but do this: python configure.py --boost-inc-dir=/Users/k5patel/pool/include/boost-1_39/ --boost-lib-dir=/Users/k5patel/pool/lib/ --boost-python-libname=boost_python --cuda-root=/usr/local/cuda/ siteconf.py shoud look like: BOOST_INC_DIR = ['/Users/k5patel/pool/include/boost-1_39/'] BOOST_LIB_DIR = ['/Users/k5patel/pool/lib/'] BOOST_COMPILER = 'gcc42' BOOST_PYTHON_LIBNAME = ['boost_python-xgcc42-mt'] BOOST_THREAD_LIBNAME = ['boost_thread-xgcc42-mt'] CUDA_TRACE = False CUDA_ROOT = '/usr/local/cuda/' CUDA_ENABLE_GL = False CUDADRV_LIB_DIR = [] CUDADRV_LIBNAME = ['cuda'] CXXFLAGS = [] LDFLAGS = [] change setup.py so it has this: if 'darwin' in sys.platform: # prevent from building ppc since cuda on OS X is not compiled for ppc if "-arch" not in conf["CXXFLAGS"]: conf["CXXFLAGS"].extend(['-arch', 'i386','-m32']) if "-arch" not in conf["LDFLAGS"]: conf["LDFLAGS"].extend(['-arch', 'i386','-m32']) the key is -m32 as indicated by http://article.gmane.org/gmane.comp.python.cuda/1089 3) do sudo make install. ensure that there are no warnings around the line of "different architecture" 4) once built, go to the test directory and type in: python test_driver.py hopefully it passes don't type: sudo python test_driver.py as indicated elsewhere I hope this could be of help to those who couldn't get PyCUDA 0.93 working on their system. The main problem has to do with SL's 64-bitness and CUDA's lack of it (and hence PyCUDA).... krunal _______________________________________________ PyCUDA mailing list [email protected] http://tiker.net/mailman/listinfo/pycuda_tiker.net
