[Top][All Lists]

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

[Help-glpk] Re: Instalation Problems

From: Andrew Makhorin
Subject: [Help-glpk] Re: Instalation Problems
Date: Thu, 03 Apr 2003 01:02:03 +0400

>I decompressed the files and I tried to compile de <sample.c> in borland 
>C++ 5.01.
>  - No errors ocurred during compilation
>  - But there are many errors in the linking state (Error:  Error:
>Unresolved external '_glp_lpx_create_prob' referenced from module
>I think that some libraries are missing....

Neither, do I :+) Most probably you forgot to specify the glpk object

If you are using the BC++ command-line compiler, you can compile and
link 'sample.c' as follows:

c:\windows\desktop\glpk-3.3>make -f win32bc.mak check
c:\windows\desktop\glpk-3.3>cd sample
c:\windows\desktop\glpk-3.3\sample>bcc32 -I..\include sample.c ..\glpk.lib
*     0:   objval =   0.000000000e+00   infeas =   0.000000000e+00 (0)
*     2:   objval =   7.333333333e+02   infeas =   0.000000000e+00 (0)

Z = 733.333; x1 = 33.3333; x2 = 66.6667; x3 = 0

However, if you are using BC++ IDE, you should do the following:

1. Point the mouse cursor in the Project window to the [.exe] node,
   which uses glpk, and open the pull-down menu by clicking the right

2. Choose the item "Edit local options...".

3. In the popup window "Project Options" choose the topic "Directories"
   and then in the frame "Source Directoties:" add the path to the glpk
   header directory in the combobox "Include:", for example:

      Include: c:\bc5\include;c:\windows\desktop\glpk-3.3\include

4. In the same popup window "Project Options" choose the item "Add node"
   and in the popup window "Add to Project List" choose the glpk object
   library, for example:

      File name: c:\windows\desktop\glpk-3.3\glpk.lib

   The corresponding node must appear in the Project window.

5. Make/build the project as usual.

reply via email to

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