This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author cdavid
Recipients cdavid
Date 2008-12-21.08:53:29
SpamBayes Score 9.884486e-09
Marked as misclassified No
Message-id <1229849614.64.0.683517411932.issue4709@psf.upfronthosting.co.za>
In-reply-to
Content
I believe the current pyport.h for windows x64 has some problems. It
does not work for compilers which are not MS ones, because building
against the official binary (python 2.6) relies on features which are
not enabled unless MS_WIN64 is defined, and the later is not defined if
an extension is not built with MS compiler.

As a simple example:

#include <Python.h>

int main()
{
    printf("sizeof(Py_intptr_t) = %d\n", sizeof(Py_intptr_t));
    return 0;
}

If you build this with MS compiler, you get the expected
sizeof(Py_intptr_t) = 8, but with gcc, you get 4. Now, if I build the
test like:

gcc -I C:\Python26\include -DMS_WIN64 main.c

Then I got 8 as well.

I believe the attached patch should fix the problem (I have not tested
it, since building python on amd64).
History
Date User Action Args
2008-12-21 08:53:35cdavidsetrecipients: + cdavid
2008-12-21 08:53:34cdavidsetmessageid: <1229849614.64.0.683517411932.issue4709@psf.upfronthosting.co.za>
2008-12-21 08:53:33cdavidlinkissue4709 messages
2008-12-21 08:53:32cdavidcreate