When I try to compile SVN trunk, plus my recent declspecs-for-ssize_t patch, I get this error from Cygwin gcc 3.4.4: building 'collections' extension gcc -fno-strict-aliasing -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -I. -I/cygdrive/c/playground/python/trunk/./Include -I./Include -I. -I/cygdrive/c/playground/python/trunk/Include -I/cygdrive/c/playground/python/trunk -c /cygdrive/c/playground/python/trunk/Modules/collectionsmodule.c -o build/temp.cygwin-1.5.19-i686-2.5/collectionsmodule.o /cygdrive/c/playground/python/trunk/Modules/collectionsmodule.c:1314: error: initializer element is not constant /cygdrive/c/playground/python/trunk/Modules/collectionsmodule.c:1314: error: (near initialization for `defdict_type.tp_base') This is with this version of gcc: $ gcc --version gcc (GCC) 3.4.4 (cygming special) (gdc 0.12, using dmd 0.125) Copyright (C) 2004 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. So, with much uncertainty, I applied the attached patch that makes PyDict_Type be const. The whole thing then compiles fine (if you disregard one million warnings about discarding qualifiers from pointer target type), but the resulting python.exe segfaults on startup.
Logged In: YES user_id=80475 Cygwin seems to be somewhat sensitive to how subtypes are initialized in extensions. The collections.defaultdict PyTypeObject structure may need to be modified to comform to the example in lines 106 and 137 in xxsubtypes.c
Logged In: YES user_id=52562 The tp_base slot is zero then compilation finishes normally, and the resulting python.exe starts normally instead of segfaulting. Now running make test and I will report back if it fails.