...
Code Block |
---|
$ cd /usr/local/src $ mkdir TARFILES $ chown -R dev . $ cd TARFILES $ wget http://python.org/ftp/python/2.7.3/Python-2.7.3.tgz ... $ cd .. $ tar xvfz TARFILES/Python-2.7.3.tgz $ cd Python-2.7.3 $ ./configure --help $ ./configure --rpe $ make ... Python build finished, but the necessary bits to build these modules were not found: _curses _curses_panel _sqlite3 _ssl bsddb185 bz2 dl gdbm imageop readline sunaudiodev To find the necessary bits, look in setup.py in detect_modules() for the module's name. ... $ sudo yum install openssl-devel readline-devel ImageMagick sqllite-devel \ bzip2-devel gdbm-devel ncurses-devel curses-devel ... # make yum stop complaining about incomplete transaction... $ sudo yum install yum-utils $ rpm -ql yum-i $ sudo /usr/sbin/yum-complete-transaction ... $ ./configure --prefix=/usr/local/python27 $ make clean $ make $ sudo make install |
install virtualenv 2.
...
7
Code Block |
---|
$ yum list | grep python | grep virtualenv ... choose correct version $ sudo yum install python26-virtualenv ... accept defaults Complete! $ virtualenv-2.6 --help Usage: virtualenv-2.6 [OPTIONS] DEST_DIR ...wget http://python-distribute.org/distribute_setup.py $ sudo /usr/local/python27/bin/python distribute_setup.py $ wget https://raw.github.com/pypa/pip/master/contrib/get-pip.py $ sudo /usr/local/python27/bin/python get-pip.py $ sudo /usr/local/python27/bin/pip install virtualenv $ |
setting up a virtualenv
Code Block |
---|
$ mkdir virtualenvs $ cd virtualenvs $ virtualenv-2.6 --no-site-packages --python=/usr/local/python27/bin/python python27_paul $ . ~/virtualenvs/python27_paul/bin/activate (python27)$ deactivate $ |
...