How to install SeDuMi 1.3 on MATLAB R2014a, and MAC OS X 10.9.5

20 views (last 30 days)
Hello,
I am trying to install SeDuMi 1.3 to use as a solver with YALMIP R20140915. I have MATLAB R2014a on my MAC OS X 10.9.5 operating system. Also I have Xcode Version 6.0.1 on my system.
I get the following error message when I try to install SeDuMi:
>> install_sedumi
Building SeDuMi binaries...
mex -O -DUNIX -largeArrayDims bwblkslv.c sdmauxFill.c sdmauxRdot.c "-lmwlapack"
Building with 'Xcode with Clang'.
Error using mex
Undefined symbols for architecture x86_64:
"_ddot_", referenced from:
_realdot in sdmauxRdot.o
_realssqr in sdmauxRdot.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Error in install_sedumi (line 113)
eval( temp );
I appreciate your help.
Hessam.

Accepted Answer

Geoff Hayes
Geoff Hayes on 4 Oct 2014
Hessam - I downloaded the SeDuMi 1.3 source code, ran the install_sedumi, as you did, and observed the same error. This was for R2014a, OS X 10.8.5.
If you look at the blas.h file (on my Mac in /Applications/MATLAB_R2014a.app/extern/include), there is the function ddot, so you may want to try compiling the SeDuMi libraries with the blas library as well. In the install_sedumi.m file, I changed the line (111) from
temp = [ 'mex ', flags, ' ', targets64{i}, ' "', libs ,'"'];
to
temp = [ 'mex ', flags, ' ', targets64{i}, ' "', libs ,'"', ' -lmwblas'];
It seems that the install code adds either the library -lmwblas or -lmwlapack, but not both. Re-running the install, with the above change, allowed the MEX files to be build successfully. In fact, executing the code with only the BLAS library was successful too.
  4 Comments
Walter Roberson
Walter Roberson on 6 Sep 2015
Geoff looked at the source code and noticed that the symbol being reported as undefined, ddot, was listed as one of the routines known in the header file blas.h . Based upon his previous knowledge, Geoff deduced that this indicated that likely the blas library needed to be included, and so suggested adding that library to the list of required libraries, and showed how to do that.
This will not help much with Windows 10 until you manage to find a working C compiler that MATLAB will recognize.
Johan Löfberg
Johan Löfberg on 8 Sep 2015
Are you sure you have to compile it? e supply binaries for mac/win/linux https://github.com/sqlp/sedumi

Sign in to comment.

More Answers (1)

Parshotam Vaswani
Parshotam Vaswani on 11 Jun 2016
Answer by Geoff Hayes on 4 Oct 2014 has worked for me on the windows platform also... Thank You very Much Mr. Geoff.

Categories

Find more on Function Creation in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!