# MATLAB Programming/MATLAB Compiler

## Overview

Use the MATLAB Compiler to convert MATLAB programs to applications and libraries that you can distribute to end users who do not have MATLAB installed. You can compile M-files, MEX-files, or other MATLAB code. MATLAB Compiler supports all the features of MATLAB, including objects, private functions, and methods. Using MATLAB Compiler version before 3 you can generate

• Standalone C and C++ applications on UNIX, Windows, and Macintosh platforms.
• C and C++ shared libraries (dynamically linked libraries, or DLLs, on Microsoft Windows).

MATLAB Compiler version 4 no longer provides these capabilities on Windows and Linux and you can generate

• Standalone application on Linux and Windows based on Java/JIT methods
• Shared libraries on Linux and DLLs on Microsoft Windows

## Known Problems

Matlab Compiler version 4.1, distributed with Matlab 7 (R14SP1) for Solaris has a bug in the buildmcr function. This can be fixed by following these instructions:

• Quit MATLAB.
• Rename the following M-file:
  $MATLAB\toolbox\compiler\buildmcr.m (where$MATLAB is the MATLAB root directory on your machine, as returned by typing
matlabroot
at the MATLAB command prompt.)


Rename the file to buildmcr.m.old