install python 2.7 , gevent on centos 5 x86_64

Posted: 4th August 2010 by admin in Linux How to
# yum install gcc gcc-c++.x86_64 compat-gcc-34-c++.x86_64 openssl-devel.x86_64 zlib*.x86_64

install python 2.7

# wget http://www.python.org/ftp/python/2.7/Python-2.7.tar.bz2
# tar -xvjf Python-2.7.tar.bz2
# cd Python*
# ./configure --prefix=/opt/python27
# make
# make install
# vi ~/.bash_profile

replace PATH=$PATH:$HOME/bin
with PATH=$PATH:$HOME/bin:/opt/python27/bin

reload .bash_profile

# source ~/.bash_profile
# echo "/opt/python27/lib" > /etc/ld.so.conf.d/python27.conf
# ldconfig

install setuptool

# cd ~
# wget http://pypi.python.org/packages/2.7/s/setuptools/setuptools-0.6c11-py2.7.egg
# sh setuptools-0.6c11-py2.7.egg

install gevent

# yum install libevent.x86_64 libevent-devel.x86_64
# easy_install-2.7 greenlet
# wget http://pypi.python.org/packages/source/g/gevent/gevent-0.13.0.tar.gz
# tar -xvzf gevent-0.13.0.tar.gz
# cd gevent*
# python2.7 setup.py install

You must be logged in to post a comment.