http403 / pyrit

Automatically exported from code.google.com/p/pyrit
0 stars 0 forks source link

Pyrit and Snow Leopard 10.6.1 #56

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I am trying to install Pyrit on Snow Leopard 10.6.1 with the CUDA extension

Pyrit itself installed fine right out of the box, then to get the CUDA 
extension to compile i had to 
edit setup.py to add library_install_dirs like so:

cuda_extension = Extension('cpyrit._cpyrit_cuda',
                    libraries = ['ssl', 'cuda', 'z'],
                    sources = ['_cpyrit_cuda.c'],
                    include_dirs = NVIDIA_INC_DIRS,
                    library_dirs = ['/usr/local/cuda/lib'],
                    extra_compile_args = EXTRA_COMPILE_ARGS)

That managed to get it to compile, and then I installed. Pyrit runs fine but my 
GPU doesnt show 
up in list_cores. I did what the troubleshooting wiki article said to and ran

ython -c 'from cpyrit import _cpyrit_cuda'

which gives me

Traceback (most recent call last):
  File "<string>", line 1, in <module>
ImportError: dlopen(/Library/Python/2.6/site-packages/cpyrit/_cpyrit_cuda.so, 
2): Symbol not 
found: _cuCtxCreate
  Referenced from: /Library/Python/2.6/site-packages/cpyrit/_cpyrit_cuda.so
  Expected in: flat namespace
 in /Library/Python/2.6/site-packages/cpyrit/_cpyrit_cuda.so

Im guessing that the python extension isn't finding the libcuda.dylib at 
runtime? I'm not much of 
a Python guy though so I don't really know how to go about fixing it.

Original issue reported on code.google.com by kabal...@gmail.com on 14 Oct 2009 at 8:40

GoogleCodeExporter commented 9 years ago
I'll take a look when I get 10.6.1

Original comment by lukas.l...@gmail.com on 15 Oct 2009 at 6:57

GoogleCodeExporter commented 9 years ago
In 10.6, most things default to x86_64, including the standard Python 
interpreter. CUDA 2.3a only supports 
i386. You will need to run Python in 32bit mode to get CUDA running.

Original comment by stew...@gmail.com on 17 Dec 2009 at 12:54

GoogleCodeExporter commented 9 years ago
thanks stewreo! python 2.6 is the default version for OS X 10.6, and since its 
64-bits, it 
doesnt work. Just use python 2.5 and everything will work! (just type 
'python2.5' instead 
of 'python')...

Original comment by thuang513@gmail.com on 17 Dec 2009 at 1:06

GoogleCodeExporter commented 9 years ago
closed for now. Will track 10.6.1 in another bug...

Original comment by lukas.l...@gmail.com on 8 Jan 2010 at 10:56

GoogleCodeExporter commented 9 years ago

Original comment by lukas.l...@gmail.com on 8 Jan 2010 at 10:56

GoogleCodeExporter commented 9 years ago
Hi there. I'm having the same issue compiling from SVN.

    Python 2.5.5 (r255:77872, Feb 25 2010, 00:23:39) 
    [GCC 4.2.1 (Apple Inc. build 5646)] on darwin

core:~/Downloads/pyrit_svn/cpyrit_cuda $ python -c 'from cpyrit import 
_cpyrit_cuda'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
ImportError: 
dlopen(/opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5
/site-
packages/cpyrit/_cpyrit_cuda.so, 2): Symbol not found: _cuCtxCreate
  Referenced from: /opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-
packages/cpyrit/_cpyrit_cuda.so
  Expected in: flat namespace
 in /opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-
packages/cpyrit/_cpyrit_cuda.so

Any suggestions?

Original comment by ravez...@gmail.com on 25 Feb 2010 at 8:06