Main Content

addDirective

Class: coder.make.BuildTool
Namespace: coder.make

Add directive to Directives

Syntax

h.addDirective(name,value)

Description

h.addDirective(name,value) creates a named directive, assigns a value to it, and adds it to coder.make.BuildTool.Directives.

Input Arguments

expand all

Object handle for a coder.make.BuildTool object, specified as a variable.

Example: tool

Name of directive, specified as a character vector.

Data Types: char

Value of directive, specified as a character vector.

Data Types: char

Examples

tc = coder.make.ToolchainInfo;
tool = tc.getBuildTool('C Compiler');
tool.addDirective('IncludeSearchPath','-O');
tool.setDirective('IncludeSearchPath','-I');
tool.getDirective('IncludeSearchPath')
ans  = 

-I

Version History

Introduced in R2013a