Borrar filtros
Borrar filtros

How do I associate a C compiler (not MinGW)?

3 visualizaciones (últimos 30 días)
yonathan nativ
yonathan nativ el 10 de Dic. de 2017
Editada: Walter Roberson el 10 de Dic. de 2017
I want to call from MATLAB function from a lib file (compiled in C - probably in MSVS).
All instructions I found on Mathworks get me: "No supported compiler or SDK was found. You can install the freely available MinGW-w64 C/C++ compiler; see Install MinGW-w64 Compiler"
I would have followed the instruction but I've noticed this: "Library (.lib) files generated by Microsoft® Visual Studio® are not compatible with MinGW"
So I rather not to. I have MSVS installed on my (windows) computer, I can't find anywhere instructions of how to 'tell' Matlab to work with this compiler.
Any one can point me to instructions how to define a C compiler i Matlab (other than MinGW)?
P.S. I am using the coder toolbox and generating MEX files all the time so I guess somewhere my Matlab does have access to a C compiler

Respuestas (1)

Walter Roberson
Walter Roberson el 10 de Dic. de 2017
Editada: Walter Roberson el 10 de Dic. de 2017
mex -v -setup C
Note: if your VS compiler is not "Professional" then it will probably not work with MATLAB, unless you are using a fairly old version of MATLAB, or you are using VS 2017 with R2016b or newer.
Also, there are some subtle version conflicts: for example in R2017a, VS 2017 is not supported for MATLAB Compiler SDK or MATLAB Coder, and in R2017b, VS2017 is not supported for Stateflow.

Etiquetas

Productos

Community Treasure Hunt

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

Start Hunting!

Translated by