Main Content

Make command

Make command and options for initiating build process

Model Configuration Pane: Code Generation

Description

The Make command parameter specifies the make command and makefile options to use to initiate the build process.

Note

This parameter appears when the model is configured to use a template makefile-based code generation system target file, as described in Configure Toolchain (ToolchainInfo) or Template Makefile Build Process.

Dependencies

This parameter is enabled by Generate makefile.

Settings

make_rtw (default)

An internal MATLAB® command used by the code generator to control the build process. The specified make command is invoked when you start a build.

  • Each target has an associated make command, automatically supplied when you select a system target file.

  • Some third-party targets supply a make command. See the vendor documentation.

  • You can supply makefile options in the Make command field. The code generator passes the options to the command-line invocation of the make utility, which adds them to the overall flags passed to the compiler. Append the options after the make command, as this example shows:

    make_rtw OPTS="-DMYDEFINE=1"

    The syntax for makefile options varies for different compilers.

Tips

  • Most targets use the default command.

  • You should not invoke make_rtw or other internal make commands directly from MATLAB code. To initiate a model build from MATLAB code, use documented build commands such as slbuild or slbuild.

Recommended Settings

ApplicationSetting
DebuggingNo impact
TraceabilityNo impact
EfficiencyNo impact
Safety precautionNo recommendation

Programmatic Use

Parameter: MakeCommand
Type: character vector
Value: valid make command MATLAB language file
Default: 'make_rtw'

Version History

Introduced in R2007a