Python 2.5 zlib trouble

Christian Heimes lists at
Sun Sep 25 02:51:28 CEST 2011

Am 25.09.2011 01:33, schrieb Benjamin Kaplan:
> There is no binary installer on that page. That means you downloaded
> the source code and compiled it yourself. Yes, you didn't patch it.
> But it's still a self-compiled version of Python.
> In order to get zlib in a self-compiled version of Python, you need to
> install the appropriate -dev package. From a quick look at the
> repository, I think it's zlib1g-dev but I'm not sure.
> On Ubuntu, the development headers are in a different package than the
> libraries themselves. The development headers aren't needed when
> you're installing a binary that someone else compiled (for instance,
> anything you get from the package manager) but are needed if you're
> trying to build anything that uses the library. Since a good chunk of
> the Python stdlib isn't actually necessary to run Python, you can
> successfully build Python without getting a good chunk of the modules.
> ../configure will give you a list of the modules that won't get built
> at the end of its output.

On recent Ubuntu and Debian versions, the dev packages aren't enough for
old versions of Python. Anything older than Python 2.7.2 requires a
tweak in order to make Python find the shared libraries. It's all
explained in my blog posting.

Debian's new multiarch features has broken Python's main
because it tries to find the libraries itself instead of relying on and gcc. Barry has already fixed the issue for 2.7.2 and recent 3.2.


PS: Linux 3.x is going to cause trouble with older versions of Python,
too. Wanna know more? Have a look:

More information about the Python-list mailing list