Here I describe how I built the getfem_toolbox. This description is based on the original readme. I hope it is helpful. Feel free to correct this description!
$HOME/getfem++-3.1/./configure --enable-matlab=yes --with-getfem-config=$HOME/getfem++-3.1/getfem-config-notinstalled --with-toolbox-dir=$HOME/getfem_toolbox make
export PATH=/c/Program\ Files/MATLAB/R2007b/bin:$PATH
cd getfem++-3.1/interface/src/matlab "c:/Progra~1/MATLAB704/bin/win32/mex.bat" -v -f c:/path/to/mexopts.bat -output gf_matlab -g -D"MATLAB_RELEASE=14" ./gfm_mex.c ./gfm_common.c -I. -I.. ./../gfi_array.c ../.libs/libgetfemint.a C:/msys/1.0/home/<YOUR_MSYS_USER>/getfem++-2.0/src/.libs/libgetfem.a c:/MinGW/lib/libstdc++.a
cd getfem++-3.1/interface/src/matlab mex -v -output gf_matlab -g -D"MATLAB_RELEASE=14" ./gfm_mex.c ./gfm_common.c -i.html">I. -i.html">I.. ./../gfi_array.c ../.libs/libgetfemint.a C:/msys/1.0/home/<YOUR_USERNAME>/getfem++-3.1/src/.libs/libgetfem.a c:/MinGW/lib/libstdc++.a
When using the graphical interface of matlab, a number of intermediate messages of getfem get lost (for example those displaying the progression of iterative solvers). You may want to launch matlab from the msys shell instead of launching it from its shortcut. In that case, those intermediate messages from getfem will be displayed in the msys window.
That's what I did - might be incomplete etc.
# Determine MATLAB directory, mex must be in the PATH. MATLAB_ROOT=`mex -v 2>&1 | grep "MATLAB " | awk '{print $4}' | sed -e '2,$d'` # May be thats not all you need sudo apt-get install build-essential subversion libtool # Get the sources svn co http://svn.gna.org/svn/getfem/trunk getfem cd getfem/getfem++/ ./autogen.sh ./configure --enable-matlab --with-pic --with-matlab-toolbox-dir=$MATLAB_ROOT/toolbox/getfem_toolbox make && make check # If all checks passed do sudo make install # Add the path to the matlab path definitions file echo "p=[matlabroot,'/toolbox/getfem_toolbox:',p];" | sudo tee -a $MATLAB_ROOT/toolbox/local/pathdef.m # Then I had to move the old libraries to a different folder to make matlab use the newer ones from ubuntu cd $MATLAB_ROOT/sys/os/glnxa64/ sudo mkdir old sudo mv libstdc* libgcc_s* old/. # If you see an empty output, the path should be added correctly $MATLAB_ROOT/bin/matlab -nojvm -nosplash -r "gf_workspace('clear'); exit;"