[Ipopt] Ipopt and MATLAB (fwd)

Benjamin S. Skrainka b.skrainka at ucl.ac.uk
Wed Jun 24 12:57:10 EDT 2009


I forgot to mention that if you are using MacTex (a popular LaTeX
distribution for OS/X),
there is another application called mex in /usr/texbin which conflicts
with the MATLAB mex command.
I had to specify the absolute path to the mex in the MATLAB .app.

Thanks for making IPOPT available!

Cheers,

Ben

On Wed, Jun 24, 2009 at 5:29 PM, Peter Carbonetto<pcarbo at cs.ubc.ca> wrote:
> 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




More information about the Ipopt mailing list