This is a beginner question, and a follow-up to this one, where I was pointed to GLPK.
I'm trying to get PyGLPK, a Python binding for the GNU Linear Programming Kit up and running, but no matter what I do, I can't seem to build and install GLPK so that Python finds it correctly. This comes after running ./configure, make, and sudo make install on the GLPK libraries, and following the instructions for PyGLPK.
Specifically, here is the error I get:
>>> import glpk
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site- packages/glpk.so, 2): Symbol not found: __glp_lpx_print_ips
Referenced from: /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/glpk.so
Expected in: dynamic lookup
I assume that something isn't linking to somewhere else, and that it probably has something to do with paths and environment variables. However, here's where my abilities in the shell fail, and I'm at a loss over what to do next.
Edits
I'm able to run the GLPK Solver (
glpsol
) from the command line, so I know that it works, at least in theory.At one point I tried using MacPorts to install a version of GLPK. I've since uninstalled this version, albeit using MacPorts.
Here's the result of using
otool -L
, which apparently is the OS X answer toldd
:/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/glpk.so: /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 88.3.11)
Again, there is probably a simple answer to this, but I haven't had any luck with Google using the terminology I know.