The compiler, through its exhaustive set of options, gives you access to the tools you need to do your job. If you want a simplified approach to compilation, you can use one simple macro that allows you to quickly accomplish basic compilation tasks. Macros let you group several options together to perform a particular type of compilation.
This table shows the relationship between the macro approach to accomplish a standard compilation and the multioption alternative.
-m option tells the compiler to produce
a standalone application. The
-m macro is equivalent
to the series of options
-W main -T link:exe
This table shows the options that compose the
and the information that they provide to the compiler.
Produce a wrapper file suitable for a standalone application.
Create an executable link as the output.
You can change the meaning of a macro by editing the corresponding
For example, to change the
-m macro, edit the file
This changes the meaning of
-m for all users
of this MATLAB® installation.
MCCSTARTUP functionality has been
replaced by bundle technology, the
that resides in
toolbox\compiler\bundles can be
used to specify default options to the compiler.
For example, adding
-mv to the
causes the command:
mcc -mv foo.m
macro_defaultfile causes the command:
mcc -W 'lib:libfoo' -T link:lib foo.m
mcc -v -W 'lib:libfoo' -T link:lib foo.m