Mex Compilation on Matlab2014a with Mac OSX10.10

Hi, the library that i am trying to compile is spams http://spams-devel.gforge.inria.fr. When i run the compile file after setting some paths to the compiler it complains of the dynamic linker (ld) being unable to find symbols. I did mex -v and the output i get is as below
-> MATLAB = /Applications/MATLAB_R2014a.app
-> CC = xcrun -sdk macosx10.11 clang
-> CC flags:
CFLAGS = -fno-common -arch x86_64 -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk -mmacosx-version-min=10.11 -fexceptions
CDEBUGFLAGS = -g
COPTIMFLAGS = -O2 -DNDEBUG
CLIBS = -L/Applications/MATLAB_R2014a.app/bin/maci64 -lmx -lmex -lmat -lc++
arguments = -DMX_COMPAT_32
-> CXX = xcrun -sdk macosx10.11 clang++
-> CXX flags:
CXXFLAGS = -fno-common -fexceptions -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk -mmacosx-version-min=10.11 -stdlib=libc++
CXXDEBUGFLAGS = -g
CXXOPTIMFLAGS = -O2 -DNDEBUG
CXXLIBS = -L/Applications/MATLAB_R2014a.app/bin/maci64 -lmx -lmex -lmat -lc++
arguments = -DMX_COMPAT_32
-> FC = gfortran
-> FC flags:
FFLAGS = -fexceptions -m64 -fbackslash
FDEBUGFLAGS = -g
FOPTIMFLAGS = -O
FLIBS = -L/Applications/MATLAB_R2014a.app/bin/maci64 -lmx -lmex -lmat -L -lgfortran -L -lgfortranbegin
arguments = -DMX_COMPAT_32
-> LD = xcrun -sdk macosx10.11 clang
-> Link flags:
LDFLAGS = -arch x86_64 -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk -mmacosx-version-min=10.11 -bundle -Wl,-exported_symbols_list,/Applications/MATLAB_R2014a.app/extern/lib/maci64/mexFunction.map
LDDEBUGFLAGS = -g
LDOPTIMFLAGS = -O
LDEXTENSION = .mexmaci64
arguments =
-> LDCXX =
-> Link flags:
LDCXXFLAGS =
LDCXXDEBUGFLAGS =
LDCXXOPTIMFLAGS =
LDCXXEXTENSION =
arguments =
the LDCXX is not set. Can someone please help me setup the LDCXX. I am using Xcode 7.0.1 with Mac OSX10.10.5
Thanks
-Haris

Answers (0)

This question is closed.

Asked:

on 13 Oct 2015

Closed:

on 20 Aug 2021

Community Treasure Hunt

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

Start Hunting!