[Numpy-discussion] New to ctypes. Some problems with loading shared library.

Lou Pecora lou_boog2000@yahoo....
Tue Feb 5 10:49:47 CST 2008

> Well, it's looking for test1ctypes.dylib, which I
> guess is a MacOSX
> shared library?  Meanwhile, you made a
> test1ctypes.so, which is why it
> can't find it.  You could try using this instead:
> _test1 = N.ctypeslib.load_library('test1ctypes.so',
> '.')
> or try to get gcc to make a test1ctypes.dylib.
> Ryan

Thanks, Ryan.  You were on the right track.  I changed
the name of the file in the load_library call to
test1ctypes.so and I had to put in the full path to
the file as the second argument.  The default path was
to my home directory.  I could probably change paths
with a python os call, too.  

Anyway, IT WORKED!  How 'bout that?  One simple
example down and now on to more complex things.

Thanks, again.

-- Lou Pecora,   my views are my own.

Looking for last minute shopping deals?  
Find them fast with Yahoo! Search.  http://tools.search.yahoo.com/newsearch/category.php?category=shopping

More information about the Numpy-discussion mailing list