Thread Subject: deploying standalone application with mex files

Subject: deploying standalone application with mex files

From: John

Date: 6 May, 2009 15:20:01

Message: 1 of 2

Hi ,
    I am having trouble using deploytool to compile and package my application on windows. I am using Maltab R2008a. My source has lots of m files and a few C mex files. I am able to compile the mex files successfully and run them without any issues. However,w hen I try to compile the entire application using deploytool, it produces errors like 'undefined reference to mexFunction' ,'Undefined reference to mxFree' etc. I added the C mex files into the C/C++ folder in deploytool. I also tried addign the compiled mex file in the OtherFiles folder and that did not throw any error during compilation, but the application crashes when I deploy and run it.

Any help/pointers would be highly appreciated.Please let me know if you need any additional information.

Thanks,
Sindy

Subject: deploying standalone application with mex files

From: John

Date: 13 May, 2009 15:45:03

Message: 2 of 2

This was resolved by mathworks support.Just thought I'll post the solution here if anyone comes across this issue in the future -

1) Adding C mex files into C/C++ folder in deploytool project does not work. Add the compiled mexw32 file in the 'OtherFiles' folder of the deploytool project.

2) Make sure the compiled mexw32 file has been compiled in the same version of matlab where you are creating the deploytool project.



"John" <sjohn@cnbc.cmu.edu> wrote in message <gts9r1$uj$1@fred.mathworks.com>...
> Hi ,
> I am having trouble using deploytool to compile and package my application on windows. I am using Maltab R2008a. My source has lots of m files and a few C mex files. I am able to compile the mex files successfully and run them without any issues. However,w hen I try to compile the entire application using deploytool, it produces errors like 'undefined reference to mexFunction' ,'Undefined reference to mxFree' etc. I added the C mex files into the C/C++ folder in deploytool. I also tried addign the compiled mex file in the OtherFiles folder and that did not throw any error during compilation, but the application crashes when I deploy and run it.
>
> Any help/pointers would be highly appreciated.Please let me know if you need any additional information.
>
> Thanks,
> Sindy

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
deploytool John 6 May, 2009 11:24:02
mex John 6 May, 2009 11:24:02
rssFeed for this Thread

Contact us at files@mathworks.com