
2 MATLAB Compiler mcc
2.1 Preliminary Notes
The MATLAB Compiler mcc can translate M-files into C or C++ source code. The
resulting files can be used in any of the supported executable types (MEX, stand-alone
executable, library) by generating an appropriate wrapper file. A wrapper file contains
the required interface between the mcc-generated code and a supported executable type.
For compilation and linking any ANSI C or C++ compiler may be used. Therefore the
mcc itself is not a ANSI C or C++ compiler! At the linking stage the resulting object files
are linked against the MATLAB C/C++ Math and Graphics Libraries (see: Figure 1).
To create a stand-alone C or C++ application, the the following steps are processed by
the MATLAB Compiler mcc:
1. Translation of the given M-files into C or C++ source code.
2. Generation of additional C or C++ source code modules (wrapper files).
3. Invocation of a C or C++ compiler and linker.
Figure 1: Creating a C stand-alone application [4]
2
Commentaires sur ces manuels