1

I am using Red Hat Enterprise Linux Server release 6.3. By default it is bundled with Python 2.6.6.

However I need to have Python 2.7.6. So performed an alternative custom install using the following steps:

wget http://www.python.org/ftp/python/2.7.6/Python-2.7..tgz
tar -xzf Python-2.7.6.tgz
cd Python-2.7.6
./configure
make altinstall

All went find and I got the Python-2.7.6 installed properly. For example,

[root@nc9037034032 Python-2.7.6]# python2.7 -V
Python 2.7.6

Now I need to install additional packages for the Python 2.7.6. For example, I need to install requests library for this python 2.7.6.

How to do this? I am familiar with installing packages in python using pip, easy_install,..... However they are installing in the old python i.e. 2.6.6. How to do it for the newly custom installed python?

Exploring
  • 2,493
  • 11
  • 56
  • 97
  • You need to install the distribute or setup packages for python2.7 see http://stackoverflow.com/questions/4324558/whats-the-proper-way-to-install-pip-virtualenv-and-distribute-for-python?rq=1 – mmmmmm Jan 13 '14 at 17:52
  • Sounds like [virtual environment](http://www.virtualenv.org/) is something you wanna look into. – Martol1ni Jan 13 '14 at 17:52
  • dont think the answer is given in that SO answer. My situation is different here as I have two python version in the same box. – Exploring Jan 13 '14 at 21:17

0 Answers0