Why does mex -setup fail to locate the MinGW-64 SDK that I just installed from the Add-On explorer in Matlab R2017a?
38 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
I just installed MinGW-64 using the Add-On explorer. I run mex -setup from the Matlab command prompt, and I get the following error message:
Error using mex No supported compiler or SDK was found. You can install the freely available MinGW-w64 C/C++ compiler; see Install MinGW-w64 Compiler. For more options, visit http://www.mathworks.com/support/compilers/R2017a/.
0 comentarios
Respuestas (1)
Michelle Wu
el 13 de Mzo. de 2017
It is probably because the environment variable MW_MINGW64_LOC is not set correctly during installation. Usually this variable should be set with the path of the MinGW installation folder. However, on some systems where users have limited privileges, there may policies in place preventing environment variables from being set.
In order to see whether the MW_MINGW64_LOC environment variable is set, run the "mex" command in verbose mode:
mex -setup -v
The solution is to have an administrator set the variable.
Please refer to the following MATLAB Answers post for more information:
1 comentario
Walter Roberson
el 13 de Mzo. de 2017
I speculate you might have to exit MATLAB and re-enter for it to get the environment variable.
Ver también
Categorías
Más información sobre MATLAB Support for MinGW-w64 C/C++ Compiler en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!