Use of matlab dlls as third party dependencies
9 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Pierre-Emmanuel de Robien
am 10 Jan. 2025
Bearbeitet: 埃博拉酱
am 21 Jan. 2025
Hi guys,
I am trying to build a Qt application which will generates .mat files. Last year I was using a 32 bits Qt framework and it was working fine. I had two matlab dlls (coming from matlab 2018b if I do remember well) as third party dependencies: libmat.dll and libmx.dll, I could compile and execute my application without any issue.
But the application will frequently use more than 2 Gb of RAM and than is why I am migrating to a 64 bits Qt framework. However Qt is struggling to load matlab dlls. Either a dll is missing or I get the error code 0xc000007b which means that I am using 32-bits and 64-bits dlls.
I already post a question about Qt on their forum but we where not able to find a solution. That is why I am posting the question here.
I have matlab 2022b installed on my machine (Windows x64 bits)
I can see in <matlab_root>/bin/win64 folder the dlls I am looking for: libmat.dll and libmx.dll and I am using mat.h, matrix.h and tmwtypes.h from <matlab_root>/extern/include folder in the source code to interact with the dlls. At that point, I am able to compile (So the matlab libraries are found by Qt) but if I try to start the application, Qt is complaining because some dlls are missing: libmwfl.dll, libmwflstorageutility.dll etc..
Apparently, Qt is also looking in the Windows PATH variable to search for dlls, I had a look in my system path and I can see two paths:

I know this is a matlab forum, not a Qt one, but do you guys have an idea of what I should do to use matlab as a third party dependency ?
Have a nice day,
Pierre-Emmanuel
5 Kommentare
Akzeptierte Antwort
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Write C Functions Callable from MATLAB (MEX Files) finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!