Hi Björn,
On Nov 1, 2008, at 11:57 AM, björn wrote:
How is this solved on Windows?
I believe you must have installed the version of Python that your Vim distribution was built with. For standard builds I think this is 2.3. Cream builds use 2.5 or maybe 2.4. I can verify this on Monday at work.
Please, even if nobody knows the answer to this question I urge you to
look into it and help me out, else I will be forced to continue distributing MacVim with Python 2.3.
I don't have an answer, but I'm willing to help if I can. I'm not 100% sure there will be a solution short of having separate Leopard and Tiger builds, but it's worth trying.
One thing that might work is to use "Py_InitModule3" instead of "Py_InitModule4" in if_python.c:2361. The former does not take an API version parameter, so that check won't be performed. Even the online Python docs [1] say that use of "Py_InitModule3" is preferred in most cases. I haven't got Tiger setup at the moment to try this out. I'll work on getting Tiger going this weekend so I can try your patch.
Another thing to try would be downloading the Python 2.3 sources and using the headers from there when building, instead of the Python 2.5 headers included with Leopard. This would ensure the PYTHON_API_VERSION matches. But I'm not sure if this would fix the problem or just invert it (no warn on Tiger, warn on Leopard).
Jason [1] http://www.python.org/doc/2.5.2/api/allocating-objects.html
smime.p7s
Description: S/MIME cryptographic signature
