mex and C/C++ compiler error
조회 수: 2 (최근 30일)
이전 댓글 표시
I'm trying to setup the compliers for C/C++ code generation on MATLAB R2022a, to generate audio plugins to be used in DAWs.
I'm using a macOs Ventura 13.1 system, I installed Xcode version 14.2, but when i try to setup the code compiler with the commands
"mex -setup", "mex -setup C" or "mex -setup C++" I always get the following error message, the same I got before installing Xcode
this is what i get as output:
>> mex -setup
Error using mex
Supported compiler not detected. For options, visit https://www.mathworks.com/support/compilers.
>> mex -setup C
Error using mex
Supported compiler not detected. For options, visit https://www.mathworks.com/support/compilers.
>> mex -setup C++
Error using mex
Supported compiler not detected. For options, visit https://www.mathworks.com/support/compilers.
>> mex -setup -v
Verbose mode is on.
... Looking for compiler 'Xcode with Clang' ...
... Looking for environment variable 'DEVELOPER_DIR' ...No.
... Executing command 'xcode-select -print-path' ...Yes ('/Library/Developer/CommandLineTools').
... Looking for folder '/Library/Developer/CommandLineTools' ...Yes.
... Executing command 'which xcrun' ...
Yes ('/usr/bin/xcrun').
... Looking for folder '/usr/bin' ...Yes.
... Executing command 'defaults read com.apple.dt.Xcode IDEXcodeVersionForAgreedToGMLicense' ...No.
... Executing command 'defaults read /Library/Preferences/com.apple.dt.Xcode IDEXcodeVersionForAgreedToGMLicense' ...Yes ('14.2').
... Executing command '
agreed=14.2
if echo $agreed | grep -E '[\.\"]' >/dev/null; then
lhs=`expr "$agreed" : '\([0-9]*\)[\.].*'`
rhs=`expr "$agreed" : '[0-9]*[\.]\(.*\)$'`
if echo $rhs | grep -E '[\."]' >/dev/null; then
rhs=`expr "$rhs" : '\([0-9]*\)[\.].*'`
fi
if [ $lhs -gt 4 ] || ( [ $lhs -eq 4 ] && [ $rhs -ge 3 ] ); then
echo $agreed
else
exit 1
fi
fi' ...Yes ('14.2').
... Executing command 'xcrun -sdk macosx --show-sdk-path' ...No.
Did not find installed compiler 'Xcode with Clang'.
Error using mex
Supported compiler not detected. For options, visit https://www.mathworks.com/support/compilers.
any help will be highly appreciated
댓글 수: 2
Geoff Hayes
2022년 12월 23일
@DARIO BENVEGNÙ - from the above error message, the link for MAC seems to suggest that Xcode14.x is not yet supported. Can you install 13.x instead?
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!