Octave-4.0.0 Installation

Latest version of octave is octave-4.0.0 which also supports GUI. In order to install octave-4.0.0, you need to install the following dependencies first:

1. Get necessary dev-tools

sudo apt-get install g++ gcc gfortran f2c make autoconf automake bison flex gperf gzip icoutils librsvg2-bin libtool perl rsync tar

2. Get necessary packages

sudo apt-get install libblas-dev liblapack-dev libpcre3-dev libarpack2-dev libcurl4-gnutls-dev epstool libfftw3-dev transfig libfltk1.3-dev libfontconfig1-dev libfreetype6-dev libgl2ps-dev libglpk-dev libreadline-dev gnuplot libgraphicsmagick++-dev libhdf5-serial-dev openjdk-7-jdk libsndfile1-dev llvm-dev lpr texinfo libgl1-mesa-dev libosmesa6-dev pstoedit portaudio19-dev libqhull-dev libqrupdate-dev libqscintilla2-dev libqt4-dev libqtcore4 libqtwebkit4 libqt4-network libqtgui4 libsuitesparse-dev libxft-dev zlib1g-dev

You can also use following to install required dependencies but it is much better to install all manually.

sudo apt-get build-dep octave

Also, Aside the octave package that installs GNU Octave, other pieces of it are split over multiple packages. These are octave-doc, octave-info, and octave-htmldoc for the documentation; liboctave-dev for the octave development header files and mkoctfile, which are required to install Octave Forge packages; and octave-dbg for the debugging symbols. Here, liboctave-dev depends on octave package, so install that first.

3. Download the package

cd /tmp
wget -c ftp://ftp.gnu.org/gnu/octave/octave-4.0.0.tar.gz
tar -xzf octave-4.0.0.tar.gz
cd octave-4.0.0

4. Configure and make

./configure --prefix=/opt/local/octave-4.0.0 CPPFLAGS=-I/usr/include/hdf5/serial LDFLAGS=-L/usr/lib/$(dpkg-architecture -qDEB_HOST_MULTIARCH)/hdf5/serial --enable-jit CPPFLAGS=-I/usr/local/java/jdk1.8.0_40/jdk1.8.0_40
make
make check

While configuring, you may get the following when building from source:

Warning: HDF5 library not found. Octave will not be able to save or load HDF5 data files.

The problem is that there are multiple versions of the hdf5 package. Octave was written with the serial version in mind but it is likely to work with the others (OpenMPI and Mpich). Due to the naming scheme done in Debian, it is required to specify the location of the libraries.

5. Install

sudo make install

There may be case, where you’ll be asked to install some dependencies. If so, install those too. By default, when you start octave, from either the terminal or by double-clicking the icon, it starts in the GUI mode. For the command-line version of octave, start it like this:

octave --no-gui

OR

octave-cli

With this you can run octave in command line mode.

Source:

http://wiki.octave.org/Octave_for_Debian_systems#Extra_dependencies_for_the_development_version

Also read- http://www.gnu.org/software/octave/doc/interpreter/Running-Configure-and-Make.html

Advertisements

Published by

kaurdavinder

I am the one who discover myself daily through reading, writing, interacting with people and expressing my thoughts to inspire them if I would be able to bring a little change to the society through my work. I write blogs, participate in various social activities and want to be a Professional Speaker. Currently, I am pursuing my post graduation in Computer Applications from Guru Nanak Dev Engineering College, Ludhiana and I’m very much active in many technical & social communities.

One thought on “Octave-4.0.0 Installation”

  1. Hi, I find your post very interesting. But I’m trying to solve a problem: I can’t install symbolic package in octave. I’m using Elementary OS (Linux), do you know how to do it? Thanks:)

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s