Hi, I'm trying to convert a simple c code to a MEX file.I used the following command.
mex c_code.c
But it gives the following error.
c:\users\abrew\appdata\local\temp\mex_vgaoax\c_code.obj: multiple definition of _main first definition is in file c:\progra~2\matlab\r2008a\sys\lcc\lib\libcrt0.obj Specified export _mexFunction is not defined Missing exports. Aborting C:\PROGRA~2\MATLAB\R2008A\BIN\MEX.PL: Error: Link of 'c_code.mexw32' failed. ??? Error using ==> mex at 207 Unable to complete successfully.
Can anyone help me to solve this issue.
Best Answer