I get the following error while installing glpkmex:
GLPKMEX - A Matlab interface for GLPK. Script installer.
Version 2.4 compatible with GLPK 4.20 (or higher)
(C) 2001-2007, Nicolo' Giorgetti.
Do you want to use graphic installer? Y/N [Y]: y
GLPK path... /home/ozdemir/opt
GLPK include files...OK
GLPK library file...OK
glpkcc.cpp:37:22: error: glplib.h: No such file or directory
glpkcc.cpp: In function ‘int glpk(int, int, int, double*, int, int*, int*, double*, double*, char*, int*, double*, int*, double*, int*, int, int, int, char*, char*, double*, double*, double*, double*, double*, double*, double*)’:
glpkcc.cpp:314: error: ‘xassert’ was not declared in this scope
glpkcc.cpp:374: error: ‘glp_ulong’ was not declared in this scope
glpkcc.cpp:374: error: expected `;' before ‘tpeak’
glpkcc.cpp:375: error: ‘tpeak’ was not declared in this scope
glpkcc.cpp:375: error: ‘lib_mem_usage’ was not declared in this scope
mex: compile of 'glpkcc.cpp' failed.
??? Error using ==> mex at 208
Unable to complete successfully.
Error in ==> makeglpkmex at 111
eval(['mex ' cmd]);
I can get rid of glplib.h line by copying the file to the related folder and I saw somewhere to change glp_ulong to glp_long. But I still can't install it.
Any help will be appreciated...
Installation under Linux 32-Bit (Ubuntu 10.04)
I tried to compile under Matlab and received a weird error. Something like
bla bla ... libstdc++.so.6: version `GLIBCXX_3... not found ... bla bla
The problem might be that Matlab's linker libstdc++.so.6 (somewhere in the Matlab directory) doesn't work with my gcc version, or libglpk0, or libgmp, or matlab configuration must be adjusted, or whatever. I didnt want to dig into the why-and-how-to-fix-adventure as you can compile mex-files directly in the terminal.
#1.Open the terminal (e.g. <Ctrl+T> in ubuntu)
#2.Open the directory where glpkcc.cpp is located:
$ cd /home/<myusername>/<mymatlabfiles>/<folder-with-glpkmex-installation>
#3.Call the mex compiler (dont forget the folder):
$ /<mymatlabinstallation>/bin/mex -I/usr/include glpkcc.cpp -lglpk -lgmp
$ /usr/local/MATLAB/R2010b/bin/mex -largeArrayDims -I/usr/include glpkcc.cpp -lglpk -lgmp
taaarraa, and there is the "glpkcc.mexglx"