Added #defines for Py_TYPE/REFCNT for python2.4.
Merge pull request #1426 from HapeMask/py3k-fixes

Added #defines for Py_TYPE/REFCNT for python2.4.