Refactor to make rtree work with both python 2 & 3

There is only one minor issue that I'm aware of currently, and it's the following:

my changes have affected the way python 2 uses the library once it's installed. For some reason for python 2, between runs it stores the results to disk, and upon the second run the result of "idx3d.intersection"... is [1, 1], for the third: [1, 1, 1] and so on. This behavior is different from python 3, which will return [1] each time. I don't know which is a bug. The test script included below demonstrates this issue.

from rtree import index
p = index.Property()
p.dimension=3
p.overwrite=True
import pdb
#pdb.set_trace()
idx3d=index.Index(b'3d_index', properties=p)
idx3d.insert(1, (0, 1, 30, 60, 23.0, 42.0))
print([x for x in idx3d.intersection( (-1, 1, 31, 62, 22, 43))])


Other than that, I think this is done.