IMHO gtk binding is bridging python and GTK, so what's the point using MSVC if GTK Runtime was build with GCC(MinGW)? Nah that's just my excuse because I don't know how to build it with MSVC :)
I've tested that I can use MinGW's pygtk with MSVC's pygobject with MinGW's GTK with MSVC's Python 2.6 and MinGW's MyPaint.... errr
Alright lets make it all MinGW's except for python shall we:
Building pygtk with MinGW could quite troublesome since official python shipped with no pkgconfig facility. So we need to define these first:
export CXXFLAGS="-Os -mtune=pentium3
export CFLAGS="-Os -mtune=pentium3
PyGObject, get latest version then extract to d:\sources, run msys terminal and navigate to pygobject's source folder. Run
"configure --without-ffi --disable-introspection --prefix=c:/python26", now we need to inject some LDFLAGS that won't accepted during configure but required during compile. Since I'm not fancied by CLI I use GrepWin:
then convert the wrong slashes:
then optionally a slight change (since it cause error):
once all done, make -j2 install
PyCairo, nothing special here just configure and make.
PyGTK,we need to enable numpy support. First download numpy superpack, then open numpy-1.6.1-win32-superpack-python2.6.exe with 7-zip inside you'll find separate installer for specific optimization (nosse, sse2 and sse3) as we targeted pentium3 unfortunately we need to use the nosse installer one.
"configure --without-glade --prefix=c:/python26"the rest is same to pygobject. If configure did not detect numpy we need to copy c:\python26\lib\site-packages\numpy\core\include\numpy folder to c:\python26\include and re-run configure.