Main Content

addBuildConfiguration

Class: coder.make.ToolchainInfo
Namespace: coder.make

Add build configuration

Syntax

h.addBuildConfiguration(bldcfg_name)
h.addBuildConfiguration(bldcfg_name, bldcfg_desc)
h.addBuildConfiguration(bldcfg_handle)

Description

h.addBuildConfiguration(bldcfg_name) creates a coder.make.BuildConfiguration object, assigns the value of bldcfg_name to Name property of the object, and adds the object to coder.make.ToolchainInfo.BuildConfigurations.

h.addBuildConfiguration(bldcfg_name, bldcfg_desc) assigns the value of bldcfg_desc to Description property of the object.

h.addBuildConfiguration(bldcfg_handle) adds an existing build configuration object to coder.make.ToolchainInfo.BuildConfigurations. The build configuration must have a name that is unique within coder.make.ToolchainInfo.BuildConfigurations.

Input Arguments

expand all

A coder.make.ToolchainInfo object, specified using an object handle, such as h. To create h, enter h = coder.make.ToolchainInfo in a MATLAB® Command Window.

Build configuration name, specified as a character vector or string scalar.

Data Types: char | string

Build configuration description, specified as a character vector or string scalar.

Data Types: char | string

Examples

h.getBuildConfigurations
ans = 

    'Faster Builds'
    'Faster Runs'
    'Debug'
bldcfg_handle = h.getBuildConfiguration('Debug')
bldcfg_handle = 

##############################################
# Build Configuration : Debug
# Description         : Default debug settings for compiling/linking code
##############################################

ARFLAGS            = /nologo $(ARDEBUG) 
CFLAGS             = $(cflags) $(CVARSFLAG) $(CFLAGS_ADDITIONAL) /c /Od $(CDEBUG)
CPPFLAGS           = $(cflags) $(CVARSFLAG) $(CPPFLAGS_ADDITIONAL) /c /Od $(CPPDEBUG)
DOWNLOAD_FLAGS     = 
EXECUTE_FLAGS      = 
LDFLAGS            = $(ldebug) $(conflags) $(LIBS_TOOLCHAIN) $(LDDEBUG) 
MEX_CFLAGS         = 
MEX_LDFLAGS        = 
MAKE_FLAGS         = -f $(MAKEFILE) 
SHAREDLIB_LDFLAGS  = $(ldebug) $(conflags) $(LIBS_TOOLCHAIN) -dll -def:$(DEF_FILE) $(LDDEBUG) 
h.addBuildConfiguration('Debug2','Variant debugging configuration')
h.setBuildConfiguration('Debug2',bldcfg_handle)
h.getBuildConfigurations
ans = 

    'Faster Builds'
    'Faster Runs'
    'Debug'
    'Debug2'

Version History

Introduced in R2013a