help-glpk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-glpk] Linker error while compiling with glpk.h


From: Michael Hennebry
Subject: Re: [Help-glpk] Linker error while compiling with glpk.h
Date: Mon, 9 Apr 2012 15:39:49 -0500 (CDT)
User-agent: Alpine 1.00 (DEB 882 2007-12-20)

On Tue, 10 Apr 2012, Psalm Niranjan wrote:

When I try to compile a C program using glpk functions, I get the the
following error at the linker. I've checked the include path and it
contains glpk.h and the lib contains libglpk. I'm compiling on a 64-bit
machine running ubuntu 11.10

/tmp/ccPR8ZKY.o: In function `main':
scheduler_main.c:(.text+0x10): undefined reference to `glp_create_prob'
scheduler_main.c:(.text+0x2b): undefined reference to `glp_set_prob_name'

IIRC most of the GLPK function names are #defined to something else.
I suspect that you did not #include glpk.h
and thus did not get the right names.
Did you get any warnings about undeclared functions?

--
Michael   address@hidden
"On Monday, I'm gonna have to tell my kindergarten class,
whom I teach not to run with scissors,
that my fiance ran me through with a broadsword."  --  Lily



reply via email to

[Prev in Thread] Current Thread [Next in Thread]