RTW.BuildInfo - Provide information for compiling and linking generated code - MATLAB (original) (raw)

Main Content

Provide information for compiling and linking generated code

Description

An RTW.BuildInfo object contains information for compiling and linking generated code.

Creation

Syntax

Description

`buildInformation` = RTW.BuildInfo returns a build information object. You can use the object to specify information for compiling and linking generated code. For example:

example

Properties

expand all

Name of generated code component.

Object Functions

Examples

collapse all

When you build generated code, the build process stores anRTW.BuildInfo object in the buildInfo.mat file. To retrieve the object, from the code generation folder that contains thebuildInfo.mat file, run:

bi=load('buildInfo.mat'); bi.buildInfo

ans =

BuildInfo with properties:

      ComponentName: 'slexAircraftExample'
             Viewer: []
             Tokens: [27×1 RTW.BuildInfoKeyValuePair]
          BuildArgs: [13×1 RTW.BuildInfoKeyValuePair]
           MakeVars: []
           MakeArgs: ''
TargetPreCompLibLoc: ''
    TargetLibSuffix: ''
          ModelRefs: []
             SysLib: [1×1 RTW.BuildInfoModules]
               Maps: [1×1 struct]
            LinkObj: []
            Options: [1×1 RTW.BuildInfoOptions]
                Inc: [1×1 RTW.BuildInfoModules]
                Src: [1×1 RTW.BuildInfoModules]
              Other: [1×1 RTW.BuildInfoModules]
               Path: []
           Settings: [1×1 RTW.BuildInfoSettings]
       DisplayLabel: 'Build Info'
              Group: ''

The object contains build information.

This example shows how to create an RTW.BuildInfo object and register source files.

Create an RTW.BuildInfo object.

buildInfo = RTW.BuildInfo;

Register source files.

buildInfo.ComponentName = 'foo1'; addSourceFiles(buildInfo, 'foo1.c');

Specify the build method and create a static library.

tmf = fullfile(tmffolder, 'ert_vcx64.tmf'); buildResult1 = codebuild(pwd, buildInfo, tmf)

Version History

Introduced in R2006a