First, download the source to some directory (here /usr/local/sage) from one of the official repositories (here it’s at U. of Washington, just for an illustration). Move to the directory and then
$ wget -c http://boxen.math.washington.edu/sage/src/sage-4.6.tar $ sudo aptitude install gcc g++ gfortran make m4 perl binutils tar $ tar -xvf sage-4.6.tar $ sudo mv sage-4.6 /usr/local $ sudo ln -s /usr/local/sage-4.6 /usr/local/sage $ cd /usr/local/sage-4.6
If you have a multiprocessor machine,
$ export MAKE="make -j4"
in which I used “4” because I have a quad core machine. Then
This is it.
Installing the Python package mpi4py
Go to the Sage installation directory, run Sage:
$ ./sage ... sage: optional_packages() ... sage: install_package('openmpi-XXX') sage: install_package('mpi4py-YYY')
I need to change the versions XXX and YYY of Open MPI and mpi4py depending on the ones found in the list obtained by optional_package().