Message95455
I'm attempting to package Python 3 for a Linux distribution, together with a stack of python extension
modules; I'm currently using Python-3.1.1. (see https://fedoraproject.org/wiki/Features/Python3F13 )
Many of these extension modules are close to compiling under both python 2 and python 3.
The page "http://wiki.python.org/moin/PortingExtensionModulesToPy3k" refers to using the macros in
intobject.h, so that all PyInt_* calls in the python 3 build are aliased to PyLong_ API hooks.
Similarly, the page: http://docs.python.org/howto/cporting.html recommends using this file.
However, that header file was removed in this commit:
http://svn.python.org/view?view=rev&revision=71697
with this message:
Issue #4910: PyNumber_Int is deprecated in 3.0.1; will be removed in 3.1.
(which links to this issue: http://bugs.python.org/issue4910 ; that issue refers to removal of the
nb_long slot).
This seems to make it harder to port modules.
Is is acceptable if I ship that header file in my distribution packages of python-3.1.1 ? (possibly
with a reworded deprecation warning?)
Alternatively, is the fix to migrate all usage of the PyInt_ API to the PyLong_ equivalents ? That
would cause a change of behavior for the python 2 builds, assuming a shared source tree.
(I'd much prefer to ship the latest in the py3k branch than to stay with 3.0.1 for this)
In any case, it seems like the porting documentation isn't in sync with the code.
Hope this is helpful. |
|
Date |
User |
Action |
Args |
2009-11-18 21:05:41 | dmalcolm | set | recipients:
+ dmalcolm |
2009-11-18 21:05:41 | dmalcolm | set | messageid: <1258578341.2.0.19051074218.issue7353@psf.upfronthosting.co.za> |
2009-11-18 21:05:40 | dmalcolm | link | issue7353 messages |
2009-11-18 21:05:39 | dmalcolm | create | |
|