| MATLAB® Compiler™ | ![]() |
| On this page… |
|---|
When you package and distribute applications and libraries that MATLAB Compiler generates, you include the MATLAB Compiler Runtime (MCR) as well as a set of supporting files generated by the MATLAB Compiler. You also set the system paths on the target machine so that the MCR and supporting files can be found.
An application or library generated by MATLAB Compiler has two parts: a platform-specific binary file and an archive file containing MATLAB functions and data. An application's binary file consists of a main function. By contrast, a library's binary file consists of multiple functions for exporting.
To create the platform-specific binaries that you specify, MATLAB Compiler generates one or more wrapper files. A wrapper file provides an interface to the compiled M-code. Wrapper files differ depending on the execution environment.
The wrapper file does the following:
Performs initialization and termination as needed by a particular interface.
Defines data arrays containing path information, encryption keys, and other information needed by the MCR.
Provides the necessary code to forward calls from the interface functions to the MATLAB functions in the MCR.
For an application, contains the main function
For a library, contains the entry points for each public M-file function. When using libraries generated by MATLAB Compiler , call the library initialization and termination routines in their client code.
MATLAB Compiler also generates a Component Technology File (CTF). This file is independent of the final target type (standalone application or library) and specific to each operating system platform. This file, which is named with a .ctf suffix, contains the MATLAB functions and data that define the application or library and is embedded in the binaries of shared C/C++ libraries and standalones by default. To override this default embedding behavior, see Overriding Default CTF Archive Embedding Using the MCR Component Cache.
Caution Do not extract the files within the.ctf file and place them individually under version control. Since the .ctf file contains interdependent MATLAB functions and data, the files within it must be accessed only by accessing the .ctf file. For best results, place the entire .ctf file under version control. |
![]() | Product Overview | Before You Begin | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |