On 28 Jan 2014 23:29, "Daniel Holth" <dholth@gmail.com> wrote:
+1
However, on Windows, I don't see most of the config vars. At least the Unicode width is easy to get at in other ways.
It's less of an issue on Windows, since we're already assuming python.orgbinary compatibility in most cases anyway. However, I'll have a look and see if this info is exposed any other way.
We also need to update the PEP/implementation to allow/add to the list of supported tags "py2.py3-none-(arch)" for cffi-type "doesn't use the ABI" extensions. This might just be a bug in the implementation...
That's definitely supposed to be allowed by the spec, specifically for that ctypes/cffi style use case. Now, whether the tools currently provide a way to *generate* a tag like that is a different question :) Cheers, Nick.
On Tue, Jan 28, 2014 at 5:40 AM, Nick Coghlan <ncoghlan@gmail.com> wrote:
Currently, bdist_wheel doesn't set the ABI tag properly on Python 2.x - the SOABI symbol it expects to find isn't present. PEP 425 also disclaims dealing with the problem.
However, PEP 3149 (which defined SOABI) explains how to define that based on 3 other syconfig flags: Py_DEBUG, Py_UNICODE_SIZE and WITH_PYMALLOC
sysconfig.get_config_var("SOABI") sysconfig.get_config_var("Py_DEBUG") 0 sysconfig.get_config_var("Py_UNICODE_SIZE") 4 sysconfig.get_config_var("WITH_PYMALLOC") 1
With those settings and the platform module (to get the current implementation), it is possible to figure out that the wheel ABI tag should be:
cp27mu
If Py_DEBUG was true, then it would be "cp27dmu" If WITH_PYMALLOC was false for some reason: "cp27u" And for a narrow Unicode build: "cp27m"
That way, the ABI tagging would work properly in 2.x as well, rather than people getting the impression that wheels can't mark the ABI compatibility requirements properly.
Cheers, Nick.
-- Nick Coghlan | ncoghlan@gmail.com | Brisbane, Australia _______________________________________________ Distutils-SIG maillist - Distutils-SIG@python.org https://mail.python.org/mailman/listinfo/distutils-sig