MATLAB 2015b (32 bit) with Windows 10. Cannot get mex -setup C++ to work with MinGW 4.9.2 (32 bit)

7 visualizzazioni (ultimi 30 giorni)
I am trying to open a 32 bit dll library and need to use 32 bit MATLAB to do so. If there is a way to do this in a later version of MATLAB running 64 bit, I'm currently unaware. I am trying to get a C++ compiler setup with MATLAB 2015b (32 bit version), but I'm unable to do so. I have tried installing TDM-gcc version 4.9.2 (the supported compiler according to https://www.mathworks.com/matlabcentral/fileexchange/52848-matlab-support-for-mingw-w64-c-c-compiler) in folder C:\TDM-GCC-32. I have tried:
setenv('MW_MINGW32_LOC','C:\TDM-GCC-32')
mex -setup C++
but I get an Error saying "no supporting complier or SDK was found."
I have also tried downloading the MinGW compiler and using that instead. Where I set the environment to look at that folder instead and have gotten the same error message.
  3 Commenti
Tom  Sobyra
Tom Sobyra il 17 Ago 2021
The original dll file was compiled in C++, wouldn't I need C++ libraries to decompile the dll file?
Rik
Rik il 17 Ago 2021
I don't know about decompiling, but you shouldn't need them to run the function, at least as far as I'm aware.

Accedi per commentare.

Risposte (1)

Fahimeh Dehghandehnavi
Fahimeh Dehghandehnavi il 4 Mar 2022
I had the same problem and this workaround resolved the issue:
1. Uninstall any Visual C++ 2010 Redistributables from the control panel first.
2. Download the corresponding offline ISO image from the Windows SDK archive.
3. After mounting the image, open F:\Setup\SDKSetup.exe directly.

Prodotti


Release

R2015b

Community Treasure Hunt

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

Start Hunting!

Translated by