About this task
The
most crucial code generation properties
to modify are the ones that interact with the makefile to build and
link the framework libraries for the new environment.
These properties are found in the specific environment metaclass under
the <lang>_CG subject for
a given language. For example, the code generation properties for
VxWorks in C++ are listed under CPP_CG::VxWorks.
The following table lists the properties help build
and link code in the new RTOS.
- Property
- Description
- CompileSwitches
- Specifies the compiler the switches to be used
for any type of build.
- CPPCompileCommand
- Specifies the environment-specific compilation
command used in the makefile. This command is referenced in the makefile
using the OMCPPCompileCommandSet variable.
If you modified the generated dependencies section
of the MakeFileContent property to generate a new .obj file
every time you compile, you need to change the CPPCompileCommand property
as follows:
" if exist $OMFileObjPath
del $OMFileObjPath
$(CPP) $OMFileCPPCompileSwitches /Fo\"$OMFileObjPath\"
\"$OMFileImpPath\" "
- CPPCompileDebug
- Modifies
the makefile compile command with switches
for building a Debug version of a component.
- CPPCompileRelease
- Modifies
the makefile compile command with switches
for building a Release version of a component.
- DependencyRule
- Specifies
how file dependencies for a configuration
are generated in the makefile.
- FileDependencies
- Specifies which framework source files to include
when building model elements. The file inclusions are generated in
the makefile.
- LinkDebug
- Specifies the special link switches used to link
in Debug mode.
- LinkRelease
- Specifies the special link switches used to link
in Release mode.
- LinkSwitches
- Specifies the standard link switches used to link
in any mode.
- ObjCleanCommand
- Specifies the environment-specific command used
to clean the object files generated by a previous build.