
On Thu, Jan 02, 2003 at 05:25:24PM -0500, Neal Norwitz wrote:
On Thu, Jan 02, 2003 at 04:40:21PM -0500, Jason Tishler wrote:
Anyway, with the attached patch to pyport.h, I was able to build Cygwin Python without any errors.
I think you can simplify the patch by doing:
#if !defined(__CYGWIN__) #define PyAPI_FUNC(RTYPE) __declspec(dllimport) RTYPE #endif
I will modify my patch to use the above instead.
But the line below (which has 35 hits) is probably faster/easier:
egrep '\.tp_.* =' */*.c
I will submit a patch to the SF Python collector to fix the following: Modules/arraymodule.c: Arraytype.tp_getattro = PyObject_GenericGetAttr; Modules/arraymodule.c: Arraytype.tp_alloc = PyType_GenericAlloc; Modules/arraymodule.c: Arraytype.tp_free = PyObject_Del; Modules/bz2module.c: BZ2File_Type.tp_base = &PyFile_Type; Modules/bz2module.c: BZ2File_Type.tp_new = PyFile_Type.tp_new; Modules/bz2module.c: BZ2File_Type.tp_getattro = PyObject_GenericGetAttr; Modules/bz2module.c: BZ2File_Type.tp_setattro = PyObject_GenericSetAttr; Modules/bz2module.c: BZ2File_Type.tp_alloc = PyType_GenericAlloc; Modules/bz2module.c: BZ2File_Type.tp_free = _PyObject_Del; Modules/bz2module.c: BZ2Comp_Type.tp_getattro = PyObject_GenericGetAttr; Modules/bz2module.c: BZ2Comp_Type.tp_setattro = PyObject_GenericSetAttr; Modules/bz2module.c: BZ2Comp_Type.tp_alloc = PyType_GenericAlloc; Modules/bz2module.c: BZ2Comp_Type.tp_new = PyType_GenericNew; Modules/bz2module.c: BZ2Comp_Type.tp_free = _PyObject_Del; Modules/bz2module.c: BZ2Decomp_Type.tp_getattro = PyObject_GenericGetAttr; Modules/bz2module.c: BZ2Decomp_Type.tp_setattro = PyObject_GenericSetAttr; Modules/bz2module.c: BZ2Decomp_Type.tp_alloc = PyType_GenericAlloc; Modules/bz2module.c: BZ2Decomp_Type.tp_new = PyType_GenericNew; Modules/bz2module.c: BZ2Decomp_Type.tp_free = _PyObject_Del; Modules/cPickle.c: Picklertype.tp_getattro = PyObject_GenericGetAttr; Modules/cPickle.c: Picklertype.tp_setattro = PyObject_GenericSetAttr; Modules/posixmodule.c: StatResultType.tp_new = statresult_new; Modules/socketmodule.c: sock_type.tp_getattro = PyObject_GenericGetAttr; Modules/socketmodule.c: sock_type.tp_alloc = PyType_GenericAlloc; Modules/socketmodule.c: sock_type.tp_free = PyObject_Del; Modules/threadmodule.c: Locktype.tp_doc = lock_doc; Modules/xxsubtype.c: spamdict_type.tp_base = &PyDict_Type; Modules/xxsubtype.c: spamlist_type.tp_base = &PyList_Type; Modules/_hotshot.c: LogReaderType.tp_getattro = PyObject_GenericGetAttr; Modules/_hotshot.c: ProfilerType.tp_getattro = PyObject_GenericGetAttr; Modules/_randommodule.c: Random_Type.tp_getattro = PyObject_GenericGetAttr; Modules/_randommodule.c: Random_Type.tp_alloc = PyType_GenericAlloc; Modules/_randommodule.c: Random_Type.tp_free = _PyObject_Del; Modules/_tkinter.c: PyTclObject_Type.tp_getattro = &PyObject_GenericGetAttr; Note that I intend to skip PC/_winreg.c unless someone feels strongly that I should change this one too. Thanks, Jason -- PGP/GPG Key: http://www.tishler.net/jason/pubkey.asc or key servers Fingerprint: 7A73 1405 7F2B E669 C19D 8784 1AFD E4CC ECF4 8EF6