[Pyrex] Pyrex build_ext Incompatible with Python 2.4 distutils

sjmachin at lexicon.net sjmachin at lexicon.net
Thu Dec 30 22:53:44 CET 2004


On 29 Dec 2004 at 3:12, Bob Ippolito wrote:

> Python 2.4's distutils changed the call signature of 
> build_ext.swig_sources to include an extra extension argument.  It
> looks like this patch to Pyrex 0.9.3 will probably work, but is
> untested:
> 
> --- build_ext.py        Fri Apr 30 08:00:46 2004
> +++ new-build_ext.py    Wed Dec 29 03:11:19 2004
> @@ -32,7 +32,7 @@
>         if self.compiler == 'mingw32':
>           self.swig_cpp = 1
> 
> -  def swig_sources (self, sources):
> +  def swig_sources (self, sources, extension=None):
>       if not self.extensions:
>         return
> 

Thanks, Bob. I'd got to the diagnosis stage, and was trying to understand 3 versions of 
build_ext.swig_sources, in order to nut out what to do next. I'm quite happy to leave that 
to the Distutils gurus :-) 

The patch appears to work -- at least in a simple case where the input payload consists 
of merely one .pyx file. 

Cheers,

John

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.copyleft.no/pipermail/pyrex/attachments/20041231/b3ba7835/attachment.html


More information about the Pyrex mailing list