Back to home page

EIC code displayed by LXR

 
 

    


Warning, /harvester/installer/PYTHON-INSTALLATION.md is written in an unsupported language. File is not indexed.

0001 Personal Python installation
0002 
0003 If you have troubles with installing modules to system-wide Python you can build your own one. A new "python" executable will be reused then in you virtual environments.
0004 
0005 Here are the steps to buils it:
0006 
0007 wget https://www.python.org/ftp/python/2.7.14/Python-2.7.14.tgz
0008 tar zxf Python-2.7.14.tgz
0009 cd Python-2.7.14
0010 ./configure —prefix=${HOME}/bin/python-2.7.14 --with-ensurepip
0011 make all install
0012 alias pip='~/bin/python-2.7.14/bin/pip'
0013 alias python='~/bin/python-2.7.14/bin/python'
0014 pip install pip --upgrade
0015 pip install --user virtualenv
0016 
0017 Check that new python has sqlite modules:
0018 
0019 python -c 'import sqlite'
0020 
0021 If it does not and you you do not have sqlite-dev package installed:
0022 
0023 wget https://sqlite.org/2018/sqlite-autoconf-3220000.tar.gz
0024 rm -rf sqlite-amalgamation-3220000
0025 tar zxf sqlite-autoconf-3220000.tar.gz
0026 cd sqlite-autoconf-3220000
0027 ./configure --prefix=${HOME}/bin/sqlite
0028 make
0029 make install
0030 export CPPFLAGS=-I${HOME}/bin/sqlite/include
0031 export LDFLAGS=-L${HOME}/bin/sqlite/lib
0032 cd ../Python-2.7.14
0033 ./configure --prefix=${HOME}/bin/python-2.7.14 --with-ensurepip
0034 make
0035 make install
0036 alias pip='~/bin/python-2.7.14/bin/pip'
0037 alias python='~/bin/python-2.7.14/bin/python'
0038 pip install pip --upgrade
0039 pip install --user virtualenv