unable to compile python 2.3 with zlib support
I just tested installing Python 2.3 with zlib support on one of our CentOS 6 servers and was able to do it as follows (installing everything into ~/python):mkdir ~/src ~/python
cd ~/src
wget http://zlib.net/zlib-1.2.5.tar.bz2
tar xjf zlib-1.2.5.tar.bz2
cd zlib-1.2.5
./configure --prefix=$HOME/python
make
make install
cd ..
wget http://www.python.org/ftp/python/2.3.7/Python-2.3.7.tgz
tar zxf Python-2.3.7.tgz
cd Python-2.3.7
./configure --prefix=$HOME/python --with-zlib=$HOME/python/include/
make
make install
A quick test after the build shows that zlib is available and working:
$ ~/python/bin/python -c "import zlib;x = zlib.compress('foo');print zlib.decompress(x)"
foo
Hope that helps!
页:
[1]