Real-Time Workshop User's Guide | ![]() ![]() |
Compiler-Specific Template Makefiles
This section documents the available compiler-specific template makefiles and common options you can use with each.
Template Makefiles for UNIX
ert_unix.tmf
grt_malloc_unix.tmf
grt_unix.tmf
rsim_unix.tmf
rtwsfcn_unix.tmf
The template makefiles for UNIX platforms are designed to be used with GNU Make. These makefile are set up to conform to the guidelines specified in the IEEE Std 1003.2-1992 (POSIX) standard.
You can supply options via arguments to the make
command.
OPTS
-- User-specific options, for example,make_rtw OPTS="-DMYDEFINE=1"
OPT_OPTS
-- Optimization options. The default optimization option is -O
. To turn off optimization and add debugging symbols, specify the -g
compiler switch in the make
command, for example,make_rtw OPT_OPTS="-g"
For additional options, see the comments at the head of each template makefile.
Template Makefiles for Visual C/C++
The Real-Time Workshop offers two sets of template makefiles designed for use with Visual C/C++.
To build an executable within the Real-Time Workshop build process, use one of the target
_vc.tmf
template makefiles:
ert_vc.tmf
grt_malloc_vc.tmf
grt_vc.tmf
rsim_vc.tmf
rtwsfcn_vc.tmf
You can supply options via arguments to the make
command.
OPTS
-- User-specific options, for example,make_rtw OPTS="-DMYDEFINE=1"
OPT_OPTS
-- Optimization options. The default optimization option is -Ot
. To turn off optimization and add debugging symbols, specify the -Zd
compiler switch in the make
command.make_rtw OPT_OPTS="-Zd"
For additional options, see the comments at the head of each template makefile.
To create a Visual C/C++ project makefile (model
.mak
) without building an executable, use one of the target
_msvc.tmf
template makefiles:
ert_msvc.tmf
grt_malloc_msvc.tmf
grt_msvc.tmf
These template makefiles are designed to be used with nmake
, which is bundled with Visual C/C++.
You can supply the following options via arguments to the nmake
command:
OPTS
-- User-specific options, for example,make_rtw OPTS="
/D MYDEFINE=1"
For additional options, see the comments at the head of each template makefile.
Template Makefiles for Watcom C/C++
drt_watc.tmf
ert_watc.tmf
grt_malloc_watc.tmf
grt_watc.tmf
rsim_watc.tmf
rtwsfcn_watc.tmf
win_watc.tmf
The Real-Time Workshop provides template makefiles to create an executable for Windows 95, Windows 98, and Windows NT using Watcom C/C++. These template makefiles are designed to be used with wmake
, which is bundled with Watcom C/C++.
You can supply options via arguments to the make
command. Note that the location of the quotes is different from the other compilers and make utilities discussed in this chapter:
OPTS
-- User specific options, for example,make_rtw "OPTS=-DMYDEFINE=1"
OPT_OPTS
-- Optimization options. The default optimization option is -oxat
. To turn off optimization and add debugging symbols, specify the -d2
compiler switch in the make
command, for example,make_rtw "OPT_OPTS=-d2"
For additional options, see the comments at the head of each template makefile.
Template Makefiles for Borland C/C++
ert_bc.tmf
grt_bc.tmf
grt_malloc_bc.tmf
rsim_bc.tmf
rtwsfcn_bc.tmf
The Real-Time Workshop provides template makefiles to create an executable for Windows 95, Windows 98, and Windows NT using Borland C/C++.
You can supply these options via arguments to the make
command:
OPTS
-- User-specific options, for example,make_rtw OPTS="-DMYDEFINE=1"
OPT_OPTS
-- Optimization options. Default is none. To turn off optimization and add debugging symbols, specify the -v
compiler switch in the make
command.make_rtw OPT_OPTS="-v"
For additional options, see the comments at the head of each template makefile.
Template Makefiles for LCC
ert_lcc.tmf
grt_lcc.tmf
grt_malloc_lcc.tmf
rsim_lcc.tmf
rtwsfcn_lcc.tmf
The Real-Time Workshop provides template makefiles to create an executable for Windows 95, Windows 98, and Windows NT using LCC compiler Version 2.4 and GNU Make (gmake
).
You can supply options
via arguments to the make
command:
OPTS
-- User-specific options, for example,make_rtw OPTS="-DMYDEFINE=1"
OPT_OPTS
-- Optimization options. Default is none. To enable debugging, specify -g4
in the make
command:make_rtw OPT_OPTS="-g4"
For additional options, see the comments at the head of each template makefile.
![]() | Template Makefiles and Make Options | Template Makefile Structure | ![]() |