MATLAB: Do I receive an error message when building a shared library using the MATLAB Compiler with LCC

compilerdlllcclibrarieslibraryMATLABMATLAB Compilershared

Why do I receive an error message when building a shared library using the MATLAB Compiler with LCC?
I am trying to build a shared library using the MATLAB Compiler with LCC . I also want to place all the generated files in directory that is different from my current directory using the following command:
mcc -v -m -W lib:libtestload testload.m -T link:lib -d dumydir
Running this command results in the following error:
:
--> "lcclnk -o "dumpdir\libtestload.dll" -dll "dumpdir\_lib8651.def" -tmpdir "dumpdir\."
-L"D:\matlab6p5\sys\lcc\lib" -libpath "D:\matlab6p5\extern\lib\win32\lcc"
dumpdir\_lib8651_stub.obj @dumpdir\8651_tmp.rsp libmmfile.lib libmatlb.lib
libmx.lib libmat.lib libmwservices.lib libmex.lib libut.lib"
MBUILD.BAT: Error: Link of 'dumpdir\libtestload.dll' failed.
??? Error using ==> mbuild
Unable to complete successfully
??? Error: An error occurred while shelling out to mbuild (error code = 1).
Unable to build executable.
Error in ==> D:\matlab6p5\toolbox\compiler\mcc.dll

Best Answer

The error message is thrown by the LCC linker when the shared library is being built in a directory that is different from the current working directory. The shared library is built, but the LCC linker still throws the error, so you can safely ignore the error messages.
The other option is to use one of the other C/C++ compilers that are supported by the MATLAB Compiler. For a list of supported compilers, review the following URL: