[SciPy-dev] Is it ok to depend on ctypes for scipy code ?

Robert Kern robert.kern@gmail....
Wed Jun 13 23:15:02 CDT 2007


David Cournapeau wrote:
> Robert Kern wrote:
>> David Cournapeau wrote:
>>> Mmh, do you mean building a library with  
>>>
>>> config.add_extension('foo',                                                        
>>>
>>>         sources=[join('src', 'vq.c') ])
>>>
>>> is not enought to load it through ctypes on windows ?
>> Correct. It will not even build.
>>
> But if this does not build, this means either a C compiler is not 
> available, or the C api for python is not there, right ? So this means 
> scipy has to be 100 % python code ?

<sigh> This is what I wrote:

"""
The linking process on Windows requires an extension module to actually have the
initfoo function.
"""

That is, the code that is compiled and linked by config.add_extension() must
actually be a Python extension module, not some shared library with arbitrary
contents.

Is that clear enough?

-- 
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless enigma
 that is made terrible by our own mad attempt to interpret it as though it had
 an underlying truth."
  -- Umberto Eco


More information about the Scipy-dev mailing list