Compiler settings for development computer environment


slrtsetCC setup
slrtsetCC 'type' 'location'



slrtsetCC setup queries the development computer for installed C compilers supported by the Simulink® Real-Time™ environment. You can then select the C compiler.

In a future release, the slrtsetCC and slrtgetCC functions will be removed.

Use the mex command. The command mex -setup sets the default compiler for Simulink Real-Time builds, provided the MEX compiler is a supported Microsoft® compiler. Use slrtsetCC('setup') only if you must specify different compilers for MEX and Simulink Real-Time.

By default, the Microsoft Visual Studio® 2015 installer does not install the C++ compiler that Simulink Real-Time requires. To install the C++ compiler, perform a custom install and select the C++ compiler. If you already installed Microsoft Visual Studio with the default configuration, rerun the installer and select the modify option.


slrtsetCC 'type' 'location' sets the compiler type and location.

To return to the default MEX compiler from a setting by slrtsetCC, type slrtsetCC 'VisualC' '', setting the compiler location to the empty character vector.


collapse all

slrtsetCC setup
Select your compiler for Simulink Real-Time.

[1] Microsoft Visual Studio 2015 in C:\Program Files (x86)\Microsoft Visual Studio 14.0\

[0] None

Compiler: 1

Verify your selection:

Compiler: Microsoft Visual Studio 2015
Location: C:\Program Files (x86)\Microsoft Visual Studio 14.0\

Are these correct [y]/n? y

slrtsetCC 'VisualC',
     'C:\Program Files (x86)\Microsoft Visual Studio 14.0\'

Input Arguments

collapse all

type must be VisualC, representing the Microsoft Visual Studio C compiler.

Example: 'VisualC'

Data Types: char

Data Types: char | string

Introduced in R2014a