Hello,
I am using the R2010b version (x64). When I try to mex a C file, MATLAB shows the following:
LINK : warning LNK4044: unrecognized option '/lkernel32'; ignored
LINK : error LNK2001: unresolved external symbol mexFunction
C:\Users\CHAITA~1\AppData\Local\Temp\mex__573OQ\templib.x : fatal error LNK1120: 1 unresolved externals
B:\MATLAB~2\BIN\MEX.PL: Error: Link of 'Hk.mexw64' failed.
??? Error using ==> mex at 208
Unable to complete successfully.
I have already set the installed compiler "Microsoft Visual C++ 2010 Express in C:\Program Files (x86)\Microsoft Visual Studio 10.0"
Please help!
Thanks...
PS. My Control panel shows that the following are present in my computer as well.
Microsoft Visual C++ Compilers 2010 Standard - enu - x64 ;
Microsoft Visual C++ 2010 x64 Redistributable - 10.0.30319 ;
Microsoft Visual Studio 2010 Express Prerequisite x64 - ENU ;
4. Microsoft Windows SDK for Windows 7 (7.1)

 채택된 답변

Titus Edelhofer
Titus Edelhofer 2011년 8월 27일

0 개 추천

Hi,
the linker misses "mexFunction", i.e., the entry point. Did you spell "mexFunction" and it's arguments correctly? Take a look at the examples given in the doc and try to compile them (and compare your mexFunction entry with the one given in those).
Titus

댓글 수: 1

Chaitanya
Chaitanya 2011년 8월 27일
Hey,
It helped. There was a typo... Thanks.
Chaitanya

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Troubleshooting in MATLAB Compiler SDK에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by