Basically we confiugre and build python to a usr defined dir, make sure we install easy_isntall and use that to install rest of packages.
A. Install easy_install:
- * Create a new dir (i.e. ~/PYTHON)
- * Download zlib
- * Compile zlib in shared mode:
- ** > ./configure -s --prefix=~/PYTHON
- ** > make
- ** > make install
- * Download Python 2.5
- * Compile and install Python pointing to zlib and telling it where to install:
- ** > ./configure --with-zlib=~/PYTHON/include --prefix=~/PYTHON
- ** > make
- ** > make install
- * Edit your env var
- ** PATH=~/PYTHON/bin:$PATH
- ** export PYTHONHOME=~/PYTHON
- ** export PYTHONPATH=$PYTHONHOME:~/PYTHON/lib
- ** export LDFLAGS="-L/anfs/bigdisc/jkt27/PYTHON/lib -L/usr/lib" (so configure can find .so/.o files)
- ** export CPPFLAGS="-I/anfs/bigdisc/jkt27/PYTHON/include -I/usr/include" (so make/GCC can find header files)
- ** alias python='~/PYTHON/bin/python'
- * Download setuptools
- * Install:
- ** sh setuptools-0.6c9-py2.5.egg --prefix=~/PYTHON
- > easy_install networkx
- Download numpy and install > python setup_all.py install
- etc.