Datasheet
C and C++ Compilers
2-16 Copyright © 1999-2001 ARM Limited. All rights reserved. ARM DUI 0067D
You can also use the
-o
option to specify a filefor the preprocessed output.
By default, comments are stripped from the output. The preprocessor
accepts source files with any extension (for example,
.o
,
.s
, and
.txt
).
See also the
-C
option.
-C
This option retains comments in preprocessor output when used in
conjunction with
-E
. This option differs from the
-c
(lowercase) option
that suppresses the link step. See Specifying output format on page 2-17
for a description of the
-c
option.
-D, symbol=value
This option defines
symbol
as a preprocessor macro. This has the same
effect as the text
#define symbol value
at the head of the source file. You
can repeat this option.
-Dsymbol
This option defines
symbol
as a preprocessor macro. This has the same
effect as the text
#define symbol
at the head of the source file. You can
repeat this option. The default value of symbol is 1.
-M
This option executes only the preprocessor phase of the compiler, as with
-E
. This option produces a list of makefile dependency lines suitable for
use by a make utility. By default, output is on the standard output stream.
You can redirect output to a file by using standard UNIX and MS-DOS
notation. For example:
compiler-name -M source.c >> Makefile
If you specify the
-o filename
option,the dependency lines generated on
standard output refer to
filename.o
, not to
source.o
. However, no object
file is produced with the combination of
-M -o filename
.
-Usymbol
This option undefines
symbol
. This has the same effect as the text
#undef
symbol
at the head of the source file. You can repeat this option.