I'm seeing this error when I run
python2.6 setup.py build on Debian Lenny from the
Compression requires the (missing) zlib module
I think the problem is that python2.6 was not build with zlib. I ran the following commands and this fixed my problem (this assumes you have the Python 2.6 source):
... there are also lots of other things that python will build with. The installer will not fail if they're missing, it'll just build without them.