[Lemon-user] Enabling GLPK library after LEMON had been installed
Kovács Péter
kpeter at inf.elte.hu
Tue Jul 26 22:20:32 CEST 2011
Hi,
> Hi everybody
>
> Both LEMON and GLPK libraries are installed on my laptop. However, I
> have the following error when compiling mip_demo.cc with the command
> "g++ -o mip_demo mip_demo.cc -lemon -lglpk":
>
> mip_demo.cc: In function ‘int main()’:
> mip_demo.cc:29: error: ‘Mip’ was not declared in this scope
> mip_demo.cc:29: error: expected ‘;’ before ‘mip’
> mip_demo.cc:32: error: ‘Mip’ is not a class or namespace
> mip_demo.cc:32: error: expected ‘;’ before ‘x1’ ...
>
> I think that GLPK was not installed when I installed LEMON.
It could be the problem. Could you check the config.h file in the
include directory (/usr/local/include/lemon/config.h)? It shows
information about the current configuration of LEMON.
You should have the following lines in this file to compile mip_demo.cc
with GLPK:
#define LEMON_HAVE_LP 1
#define LEMON_HAVE_MIP 1
#define LEMON_HAVE_GLPK 1
Best regards,
Peter
> The files are located as follows:
>
> /usr
> /lib
> libglpk.a, libglpk.so.0.28.0
>
> /local
> /lib
> libemon.a
>
> /include
> /lemon
> .h files
>
> Could you please help me :] ?
>
> Cherif
>
> Algeria
More information about the Lemon-user
mailing list