Problem using C-compiler in MATLAB. How can I setup my compiler?

2 views (last 30 days)
I recently started to work with MATLAB and I wanted to run a pre-programmed code developed by a colleague. The code makes use of C-code, so I downloaded Microsoft Visual Studio Express 2013 for Windows Desktop.
Instructions of what to do in README.txt.
What I did: I started MATLAB and since the code did not worked, I tried to setup mex. But this gave the following error (see also error.pdf in attachment in attachment): Error using mex No supported compiler or SDK was found. For options, visit http://www.mathworks.com/support/compilers/R2014a/win64.
The code I need to run can also be found in attachment.
How can I resolve these problems?
Many thanks in advance!

Answers (1)

Tushar Sinha
Tushar Sinha on 17 Jun 2014
From the error message it seems that the C compiler is not setup.
Refer to the "Supported and Compatible Compilers" link below for an information about the supported compilers with "MATLAB R2014a":
In case you decide to install the SDK 7.1 which is available at no charge, refer to the documentation below for installation of "Microsoft Windows SDK 7.1"
There is an existing issue with the installation of SDK 7.1, so, in case you see installation failed message, refer to the link below for troubleshooting the issue:
Once, it is installed successfully,restart MATLAB and run the following MATLAB command
>>mex -setup
This should show up the C compiler.
  2 Comments
Hugo Latapie
Hugo Latapie on 18 Jul 2014
Installing Microsoft Windows SDK 7.1 on Windows 8.1 is not recommended by Microsoft and may destabilize your system. You will need to uninstall updated code as discussed in the "Troubleshooting SDK installation" link above. Even the SDK 7.1 installer has some serious issues running on modern computers. I tried installing 7.1 on a surface pro 3 and the installer failed because apparently my screen resolution was "800X600 or less" while in fact it's 2160X1440.
Looking into getting visual studio 2013 express to work via some configuration tweaking.
Mandakini Jain
Mandakini Jain on 23 Apr 2016
Did you end up figuring out a solution for this? Running into this problem now.

Sign in to comment.

Categories

Find more on Introduction to Installation and Licensing in Help Center and File Exchange

Products

Community Treasure Hunt

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

Start Hunting!