Compiling octave

From GHER

Jump to: navigation, search

Contents

Install dependencies

Ubuntu

sudo apt-get build-dep octave 
sudo apt-get install libfontconfig1-dev


Fedora/Red Hat/Centos

yum install gcc-c++ gcc-gfortran make blas-devel lapack-devel gnuplot glpk-devel suitesparse-devel texinfo info \ 
 hdf5-devel qhull-devel ncurses-devel curl-devel pcre-devel readline-devel fftw3-devel fltk-devel fontconfig-devel \
 zlib-devel freetype-devel GraphicsMagick-devel 

For octave newer than 3.6.4 you also need qt4-devel.

Install Octave (all distributions)

VERSION=3.6.4
wget ftp://ftp.gnu.org/gnu/octave/octave-$VERSION.tar.bz2
tar -jxf octave-$VERSION.tar.bz2
cd octave-$VERSION
./configure --prefix $HOME/opt/octave-$VERSION | tee configure.log
make | tee make.log
make check | tee make_check.log
make install  | tee make_install.log

Relocation of octave on another place

load('octave_packages');

for i=1:4; 
   global_packages{i}.dir=strrep(global_packages{i}.dir,'u/abarth','home/abarth'); 
   global_packages{i}.archprefix=strrep(global_packages{i}.archprefix,'u/abarth','home/abarth');
end

save octave_packages global_packages
Personal tools