Matlab Compiler

1 回表示 (過去 30 日間)
chef13
chef13 2011 年 10 月 28 日
回答済み: Sorath Asnani 2014 年 9 月 16 日
Hi I want to include in a Simulink model a block called "Matlab Function" in which I wrote a simple function with the m-file editor. When I try to run my model I have this error:
"Unable to locate a C-compiler required by Stateflow and MATLAB Function blocks. Use 'mex -setup' to select a supported C-compiler."
How can I do? I'm trying to download a compiler as Windows SDK 7.1, but the download is very very slow. Have you got some links to other compilers?
Thank you in advance!

回答 (6 件)

chef13
chef13 2011 年 10 月 28 日
I have Win7 64bit and matlab 2011a.
What can i download ? Visual studio and sdk Are too slow to Download. Is there some other alternative software? Thank you!
  1 件のコメント
Walter Roberson
Walter Roberson 2011 年 10 月 28 日
The 64 bit compilers supported for your version are listed at
http://www.mathworks.com/support/compilers/R2011a/win64.html
Anything that is not in that table is not supported.

サインインしてコメントする。


Fangjun Jiang
Fangjun Jiang 2011 年 10 月 28 日
Try to run "mex -setup" anyway. I thought if you don't have any C compiler, the default lcc will be used. That should be enough if you just want to use MATLAB Function block in a Simulink model for simulation.
  1 件のコメント
Titus Edelhofer
Titus Edelhofer 2011 年 10 月 28 日
Hi Fangjun,
normally: yes. But Fabrizio has a 64Bit MATLAB that comes not with lcc (since lcc is only supported on 32bit).
Titus

サインインしてコメントする。


chef13
chef13 2011 年 10 月 28 日
So. What Can I do? I read about the answer of Derek O'Connor, but He said always to download sdk and visual studio c++ and I can't do it!
Please give me a solution :(
  1 件のコメント
Walter Roberson
Walter Roberson 2011 年 10 月 28 日
Then install the 32 bit version of MATLAB as well, and start up matlab with the -win32 flag so that you are running the 32 bit version and so would be able to use lcc.
Or get the 64 compiler software shipped to you (or buy it in a store.)

サインインしてコメントする。


Egor
Egor 2012 年 9 月 21 日
I also have the same problem but i installed the Microsoft SDK and I have visual studio 2010 installed.
  2 件のコメント
Matthew Doveton
Matthew Doveton 2013 年 5 月 31 日
How did you resolve this issue?
Walter Roberson
Walter Roberson 2013 年 5 月 31 日
VS2010 is not supported for all releases. We would need a more detailed description of the problem (including a copy of what happened with mex -setup) and to know which software releases were involved.

サインインしてコメントする。


ehsan
ehsan 2014 年 7 月 12 日
I receive the very same message. I installed microsoft VS 2013 and 2012. with 2012 I succeeded to configure mex -setup and MATLAB showed 'successfully recognized' message; still I can use MATLAB function block in SIMULINK because I receive that cursed error message!! please help it's pretty urgent my project is nearly due.

Sorath Asnani
Sorath Asnani 2014 年 9 月 16 日
Hi.. m too getting the same error message. I am using windows 8.1, Matlab R2013a 64-bit. I have installed sdk and i have visual studio 2013 installed in my PC. but whenever i run mex -setup, i am getting the same message always.. Please help me to resolve this issue.
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/R2013a/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/R2013a/win64.html
Error using mex (line 206) Unable to complete successfully.

カテゴリ

Help Center および File ExchangeMATLAB Compiler についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by