mac Matlab 2018b with xcode10 installed still No supported compiler was found

Warning: Xcode is installed, but its license has not been accepted.
Run Xcode and accept its license agreement.
> In make (line 13)
Error: path_to_libsvm/libsvm-3.23/matlab/make.m failed (line 13)
No supported compiler was found. For options, visit https://www.mathworks.com/support/compilers.
I would like to compile some C codes with mex. However, even with brand new matlab 2018b and xcode10(for now) installed on my mac could not compile these files.
Yeah, I know the warning about Xcode license issue and that's strange since I DID aceept these license by typing
sudo xcodebuild -license
in command line and accepting it.
So anyone with same experience or some suggestions ? I would be very appreciated if you do ! 0.0
bigdick_girl.jpg

3 Comments

Hi, I have the same problem. I tried various things, including the one suggested by Ran Chen, but nothing worked. Did you solve it somehow?

Sign in to comment.

Answers (2)

Hi, in the meantime I found a solution described here
Open the following 2 files
/Applications/MATLAB_Rxxxxx.app/bin/maci64/mexopts/clang_maci64.xml
/Applications/MATLAB_Rxxxxx.app/bin/maci64/mexopts/clang++_maci64.xml
where you have to replace xxxxx with your Matlab version (I have R2018b),
and add a new line with "<cmdReturns name="echo 4.3.3"/>" before the line with
"<cmdReturns name="defaults read com.apple.dt.Xcode IDEXcodeVersionForAgreedToGMLicense"/>"
To be honest I don't understand what's going on, but fortunately it works.
Hope it works for you.
Cristian

2 Comments

Thank you! That was really useful.
However, in the two files I changed the name "com.apple.dt.Xcode IDEXcodeVersionForAgreedToGMLicense" with "com.apple.dt.Xcode IDEXcodeVersionForAgreedToBetaLicense". You can check the right name for your agreed license by opening that file /Library/Preferences/com.apple.dt.Xcode.plist
Guglielmo

Sign in to comment.

I still could not compile with mex in matlab with the same environment as in titile. But I found alternative ways to solve this problem.
If you could not use mex in Matlab properly even after
sudo xcodebuild -license
sudo xcodebuild -license accept
Maybe you could try using mex in Octave instead, which could be regarded as command line tool of Matlab.
It didn't generate any errors or warning in Octave prompt when
mex -setup

Categories

Products

Release

R2018b

Asked:

on 12 Dec 2018

Commented:

on 17 Dec 2021

Community Treasure Hunt

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

Start Hunting!