Invalid mex file at a compiled matlab GUI

Hi, i am using Matlab R2012a and i have created a gui in Matlab, that uses two mex files that i compiled from C code. The whole GUI i have compiled to an executable with visual studio 2010. The same compiler i used for the compilation of the mex files.
At some computers the executable runs without problems, at other computers the gui crashes. I placed a try-catch command in the gui to get the error that is being produced... and i found out that the GUI does not recognise the compiled mex files. It says that it is an "invalid mex file" and that it can not find the mex file in a specified 'Temp' location. Still when i open the path that the error message describes, the mex file is there.
To computers that i run the executable, i have installed the MCR 4.17. All of the tested computers are running windows 7. Is there an idea on what might be going on and some computers can not find/read the mex file?
thank you in advance for the help
Dimitrios

 Réponse acceptée

Walter Roberson
Walter Roberson le 10 Jan 2013

0 votes

Are all of the systems 32 bit Windows, or all 64 bit? Is MATLAB all 32 bit or all 64 bit?
Do all of the systems have the Windows run-time libraries installed?
Have you tried using Dependency Walker ?

3 commentaires

Dimitrios
Dimitrios le 10 Jan 2013
Modifié(e) : Dimitrios le 10 Jan 2013
Hi Walter, yea i forgot,
- all windows are 64 bit - all matlab MCR are 64 bit - I do not know which runtime libraries are required. and why are they there for some and not for all the computers? - I did not try the dependency walker, is it going to tell me also which runtime libraries i require?
Jan
Jan le 10 Jan 2013
You need the runtime libraries of the used compiler. Sometimes the libs for MSVC2005 and 2008 are installed already by other software, e.g. by Matlab.
Dimitrios
Dimitrios le 10 Jan 2013
hi Jan,
thanks! I also run the Dependency Walker, and found out that there are a few .dlls that are not installed. I will find the windows runtimes that need to be installed passed with my software in order to set up the those dlls.
thanks again

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

Produits

Community Treasure Hunt

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

Start Hunting!

Translated by