[Ipopt] Library dependency issue?

Stefan Vigerske stefan at vigerske.de
Tue Jun 3 12:00:13 EDT 2008


> Stefan Vigerske wrote:
>>> I suspect that maybe there should be library dependencies on BLAS and
>>> LAPACK, as well,  but maybe I'm wrong there.
>> If Lapack and Blas are installed on the system and these are used by
>> Ipopt, then the flags go into ipopt_addlibs_cpp.txt. Otherwise, that
>> is if Lapack and Blas from ThirdParty are build and used, then the
>> libs are included into the Ipopt library.
> Evidently the 'addlibs' thing is somehome comparable to the
> `ipopt-config --libs` idea, although not yet convenient for use by the
> end user.

The use should be quite similar, instead of `ipopt-config --libs` you do 
`cat ipopt_addlibs_cpp.txt`.

> However what puzzles me here is why I don't see the dependency on LAPACK
> and BLAS and libfortran when I type 'ldd /usr/local/lib/libipopt.so'...
> if the IPOPT library uses symbols from those other libraries, why aren't
> they shown as binary dependencies?

There seem to be a difference between libraries that are "linked in" at 
runtime (these should be seen by ldd) and those that are linked at 
compile time, i.e., when you link the Ipopt library with other objects 
to an executable problem. For the latter you need to specify the flags 
as given in ipopt_addlibs_cpp.txt.
Probably there is some compiler flags that can tell which .so libs 
should be linked at runtime and therefore would be seen by ldd.

Hope I'm not totally wrong on this issue ;-),

More information about the Ipopt mailing list