Freemat Installation


Pre-Requisites
Operating System :
Currently, Windows 2000/XP, Linux and Mac OS X are supported platforms. FreeMat essentially requires GNU gcc/g++  and gfortran to build. The Win32 build  requires MINGW32. A native port to Mac OS X is now available.

Others :-  
1.  Build and install Qt 4.2 or later -http://www.trolltech.com/download/opensource.html
2.  Install g77 or gfortran (use fink for Mac OS X, use gcc-g77 package for MinGW)
3.  For Windows, you will need to install MSYS as well as MINGW tobuild FreeMat. You will also need unzip to unpack the enclosedmatio.zip archive. Alternately, you can cross-build the WIndows versionof FreeMat under Linux .

Download Freemat :-
http://downloads.sourceforge.net/freemat/FreeMat-3.0.tar.gz

Installation Instructions :-
1)   Download the source code FreeMat-3.0-src.tar.gz.
2)  Unpack the source code:  tar xvfz FreeMat-3.0-src.tar.gz
3)  
Download the source code qt-x11-opensource-src-4.2.2.tar.gz inside /afs/.enea.it/software/freemat/qt
4)   
Unpack the source code:  tar xvfz qt-x11-opensource-src-4.2.2.tar.gz
5)   Install qt  ./configure --prefix=/afs/.enea.it/software/freemat/qt/qt-x11-opensource-src-4.2.2
6)    gmake
7)    cd /afs/.enea.it/software/freemat/FreeMat-3.0
8)   
declare -x "PKG_CONFIG_PATH=/afs/.enea.it/software/freemat/qt/qt-x11-opensource-src-4.2.2/lib"
9)    cd /afs/.enea.it/software/freemat/FreeMat-3.0/libs/libFreeMat
10)  Open file
Interpreter.cpp.
11)  Add line  #include <unistd.h>  to the top of Interpreter.cpp.
12)   cd  /afs/.enea.it/software/freemat/FreeMat-3.0/libs/libXP
13)  Open file QTTerm.cpp and  edit the following lines
  col_start = (int)floor(rect.left()/((float)m_char_w));
  col_stop = (int)ceil(rect.right()/((float)m_char_w));
  col_stop = qMin(col_stop,m_width-1) ;
  row_start = (int)ceil(rect.top()/((float)m_char_h));
  row_stop = (int)floor(rect.bottom()/((float)m_char_h));
  row_stop = qMin(row_stop,m_height-1);
14 )   ./configure --prefix=/afs/.enea.it/software/freemat/FreeMat-3.0
15)   make
16)   make install