[SciPy-user] [Nipy-devel] how to wrap C++

Stefan van der Walt stefan at sun.ac.za
Sat Jan 27 16:12:37 CST 2007


On Sat, Jan 27, 2007 at 01:39:50AM -0700, Travis Oliphant wrote:
> It still depends a little.  A large library is probably more easily 
> handled with SWIG, but for custom interfaces I would say ctypes is best. 
> 
> The only problems with ctypes are
> 
> 1) Not easy to distribute the source code with the interface as you 
> can't use distutils out of the box for building shared libraries.

I've heard this being said many times, but I'm not sure I understand.
I've built shared libraries under Linux, and I've seen people do it
under Windows.  Is there a problem under MacOSX or Solaris platforms?

In the documentation, they mention:

http://pydoc.org/1.6/distutils.ccompiler.html#CCompiler-link_shared_lib

Which I saw in action in

http://www.koders.com/python/fid58C5EF5218DFA16D8F6EFBA42676DE605EBAF607.aspx

Cheers
Stéfan


More information about the SciPy-user mailing list