User`s guide

1 Getting Star ted
Using the mcc Command
Instead of the GUI, you can use the mcc command to run MATLAB Compiler.
The following table shows sample commands to create a standalone
application or a shared library using
mcc at the operating system prompt.
Desired Result Command
mcc -m mymfunction.m
Standalone application
from the M -file
mymfunction
Creates a standalone application named m ymfu nction.exe on
Windows platforms and
mymfunction on platforms that are not
Windows.
mcc -l mymfunction.m
Shared library from the
M-file
mymfunction
Creates a shared librar y n am ed mymfunction.dll on Windows,
mymfunction.so on Linux and Solaris, and mymfunction.dylib on
Mac OS X.
mcc -l file1.m file2.m file3.m
C shared library from
the M-files
file1.m,
file2.m,andfile3.m
Creates a shared library named file1.dll on Windows, file1.so on
Linux and Solaris, and
file1.dylib on Mac OS X.
mcc -l file1.m file2.m file3.m -W cpplib -T link:lib
C++ shared library from
the M-files
file1.m,
file2.m,andfile3.m
Creates a shared library named file1.dll on Windows, file1.so on
Linux and Solaris, and
file1.dylib on Mac OS X.
1-10