Error using mex (line 206) Unable to complete successfully.

1. I installed matlab2012b in windows7.
2. Compiler : Microsoft visual C++ 2008 Epress edition
3. Java version 1.7.0_02 Java<TM> SE Runtime Environment<build 1.7.0-02-b13>
Java HotSpot<TM> 64-bit Server VM<build 22.0-b13,mixed mode>
4. Microsoft .NET Framework 4 Extended -version 4.0.30319
Microsoft .NET Framework 4 Client Profile -version 4.0.30319
I have all the above software in my PC.
But when I am trying to run the model I was getting the error.
Code Error: Unable to locate a C-compiler required by Stateflow and MATLAB Function blocks.
Model Error: Error using construct_error (line 108) Library failed to build. Cannot continue build process. Use 'mex -setup' to select a supported C-compiler.
I try to run the mex -setup the following information is displayed. mex -setup
Welcome to mex -setup. This utility will help you set up a default compiler. For a list of supported compilers, see http://www.mathworks.com/support/compilers/R2012b/win64.html
Please choose your compiler for building MEX-files:
Would you like mex to locate installed compilers [y]/n? y
No supported SDK or compiler was found on this computer. For a list of supported compilers, see http://www.mathworks.com/support/compilers/R2012b/win64.html
Error using mex (line 206) Unable to complete successfully.
I couldn't see any compiler's information.
Please tell me how to resolve this issue.

 채택된 답변

Walter Roberson
Walter Roberson 2013년 12월 26일

0 개 추천

2008 Express is simply not one of the supported compilers for R2012b in 64 bit mode. You can use 2008 Professional or you install SDK7.1. Click on the link it supplied, http://www.mathworks.com/support/compilers/R2012b/win64.html for links to download 7.1

추가 답변 (3개)

Image Analyst
Image Analyst 2013년 12월 26일

0 개 추천

The "Express editions" of Microsoft Visual Studio have severe limitations. Perhaps using it's compiler outside of Visual Studio, like another program trying to use the compiler, is not allowed. You may have to upgrade from the free Express edition to a "pay" edition.
gayatri
gayatri 2013년 12월 26일

0 개 추천

After installing 2008 Professional it worked. Thank you.
gayatri
gayatri 2013년 12월 26일
편집: gayatri 2013년 12월 26일

0 개 추천

I have one more problem.
In 2007b with mex -setup complier is not shown even after installing 2008 Professional. But in 2012b it is working fine.
What could be the reason?

카테고리

도움말 센터File Exchange에서 C Shared Library Integration에 대해 자세히 알아보기

질문:

2013년 12월 26일

편집:

2013년 12월 26일

Community Treasure Hunt

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

Start Hunting!

Translated by