[python-win32] extension modules and msvc version

Zachary Turner zturner at google.com
Fri Feb 20 18:21:08 CET 2015


In other words, I'm postulating that the strict abi compatibility
requirement might be something we can fix in Python, and not rely on
Microsoft to support this in CRT
On Fri, Feb 20, 2015 at 9:18 AM Zachary Turner <zturner at google.com> wrote:

> Is it completely out of the question to change the way extension modules
> and python talk to each other? For example, suppose python is changed in a
> minor version such that it will be able to detect an extension module
> compiled with some flag, say PYTHON_EXTENSION_ABI_COMPATIBLE. Python sees
> that you compiled your extension module this way, and does something
> different internally that allows them to not free each others' memory. Like
> registering allocators with each other at startup. Unless both python and
> the extension module are built against the same minor version or higher,
> both sides continue to behave as they currently do.
>
> I don't know anything about Python implementation internals, but is
> something like this possible?
> On Fri, Feb 20, 2015 at 9:06 AM Chris Angelico <rosuav at gmail.com> wrote:
>
>> On Sat, Feb 21, 2015 at 3:41 AM, Zachary Turner <zturner at google.com>
>> wrote:
>> > Is the situation better in python 3 than it is in 2.7? And is anyone
>> aware
>> > of any ways to get around this restriction so that i can write an
>> extension
>> > module that will work with a binary release of python?
>>
>> It's going to be better, starting from Python 3.5; Microsoft is
>> guaranteeing a measure of binary compatibility for future compiler
>> versions. Unfortunately the guarantee requires some internal changes,
>> so it's moving forward only, not backward. The fate of Python 2.7 is
>> very much up in the air, because the compiler that was used for 2.7.0
>> won't be supported in 2020 (I think it might be already out of
>> support), so there's a big question of whether or not to change
>> compilers in the middle of a minor version. Neither option is good.
>>
>> ChrisA
>> _______________________________________________
>> python-win32 mailing list
>> python-win32 at python.org
>> https://mail.python.org/mailman/listinfo/python-win32
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-win32/attachments/20150220/143032f1/attachment-0001.html>


More information about the python-win32 mailing list