Fri 10 Nov 2006
These are the commands you will have to issue from the command prompt on your server in order to download the necessary libraries and applications needed to build Python. I have piped all output from each stage into log.xxxx and err.xxxx files. Make sure that you read the err.xxxx files if they are not zero length and action any errors before proceeding to the next step. The information in log.xxxx will help you troubleshoot any errors.
As I do not have root access on Westhost, I have decided to create my own tree under /usr/mylocal for libraries and executables.
Download gdbm
- ftp ftp.gnupg.org
- login: anonymous password:anon@
- cd gnu/gdbm
- passive
- dir gdbm-*
- get gdbm-1.8.3.tar.gz
- quit
- gunzip -c gdbm-1.8.3.tar.gz |tar x
- cd gdbm-1.8.3
- ./configure --prefix=/usr/mylocal >log.config 2>err.config
- make >log.make 2>err.make
- make install >log.install 2>err.install
- ls -l err.*
- edit /etc/ld.so.conf to include /usr/mylocal/lib as first line
- ldconfig
- cd ..
Download ncurses
- ftp ftp.gnupg.org
- login: anonymous
- cd /pub/gnu/ncurses
- passive
- dir ncurses*
- get ncurses-5.5.tar.gz
- get ncurses-5.5.tar.gz.sig
- quit
- gunzip -c ncurses-5.5.tar.gz |tar x
- cd ncurses-5.5
- ./configure --prefix=/usr/mylocal >log.config 2>err.config
- make >log.make 2>err.make
- make install >log.install 2>err.install
- ls -l err.*
- ldconfig
- Run test/newdemo to check your installation. Press Q to stop.
- cd ..
- ln -s /usr/mylocal/include/ncurses/ncurses.h /usr/mylocal/include/ncurses.h
- ln -s /usr/mylocal/include/ncurses/curses.h /usr/mylocal/include/curses.h
- ln -s /usr/mylocal/include/ncurses/panel.h /usr/mylocal/include/panel.h
I was unable to link to ncurses/xxxxx.h files when building Python. As a workaround, you need to define these three symbolic links
Download Python
- wget http://www.python.org/ftp/python/2.5/Python-2.5.tar.bz2
- wget http://www.python.org/download/releases/2.5/Python-2.5.tar.bz2.asc
- gpg --verify Python-2.5.tar.bz2.asc
- bunzip2 -c Python-2.5.tar.bz2 |tar x
- cd Python-2.5
- ./configure --prefix=/usr/mylocal 1>log.config 2>err.config
- make >log.make 2>err.make
- make install >log.install 2>err.install
- ls -l err.*
- ln -s /user/mylocal/bin/python /user/local/bin/python
If /usr/mylocal/bin is not in your path, then you will need to create a symbolic link for it

