[Ipopt] Ipopt and MATLAB (fwd)

Peter Carbonetto pcarbo at cs.ubc.ca
Wed Jun 24 12:29:57 EDT 2009


Ben Skrainka at University College London sent me some useful tips on 
compiling the Matlab interface on Mac OS X---see below. It looks like that 
the configure script links to a library that shouldn't be used. I'm 
forwarding them to the IPOPT mailing list as I figured that they would be 
very useful to others.

Peter Carbonetto
Ph.D. Candidate 
Dept. of Computer Science
University of British Columbia

--------------------------------------------------------

I just built Ipopt for Matlab on the latest Mac OS (10.5.7) and 
encountered a few problems with your description on COIN-OR about how to 
build the matlab interface.

1)  the new MEX suffix is mexmaci
2) LIBS includes a reference to -lcrt1.10.5.o which caused a conflict with
    another library which also defined the same symbol.  Here is the error:

ld warning: duplicate dylib /opt/local/lib/gcc43/libstdc++.6.dylib
ld warning: duplicate dylib /opt/local/lib/gcc43/libgcc_s.1.dylib
ld warning: duplicate dylib
/Applications/tools/MATLAB_R2008bSV.app/bin/maci/libz.1.dylib
ld: duplicate symbol dyld_stub_binding_helper in /usr/lib/crt1.10.5.o
and /usr/lib/bundle1.o
collect2: ld returned 1 exit status

    mex: link of ' "ipopt.mex.mexmaci"' failed.

I have attached my Makefile.

I built Ipopt with the following configure command:

../configure --prefix=/Applications/tools/coin-or/Ipopt-3.5.5
ADD_CFLAGS="-fno-common -fexceptions -no-cpp-precomp -fPIC"
ADD_CXXFLAGS="-fno-common -fexceptions -no-cpp-precomp -fPIC"
ADD_FFLAGS="-x f77-cpp-input -fPIC -fno-common"  FLIBS="-lg2c
-lfrtbegin -lSystem"    CXX=g++-mp-4.3 CC=gcc-mp-4.3
F77=gfortran-mp-4.3

I am using MacPorts for GCC, etc.

Anyway, I can now run your examples.

Thanks for putting the matlab stuff together.

Cheers,

Ben
--
Benjamin S. Skrainka
PhD Student
Department of Economics
University College London
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Makefile
Type: application/octet-stream
Size: 3066 bytes
Desc: 
Url : http://list.coin-or.org/pipermail/ipopt/attachments/20090624/f75d17cc/attachment.obj 


More information about the Ipopt mailing list