Red Hat ENTERPRISE LINUX 3 - USING CPP Using Instructions page 62

Using cpp, the c preprocessor
Hide thumbs Also See for ENTERPRISE LINUX 3 - USING CPP:
Table of Contents

Advertisement

58
-I
dir
Add the directory
tion 2.3 Search Path. Directories named by
directories.
It is dangerous to specify a standard system include directory in an
special treatment of system headers (Refer to Section 2.7 System Headers). It can also defeat the
repairs to buggy system headers which GCC makes when it is installed.
-o
file
Write output to
.
has a different interpretation of a second non-option argument, so you must use
cpp
gcc
specify the output file.
-Wall
Turns on all optional warnings which are desirable for normal code. At present this is
and
-Wtrigraphs
no options to control them.
-Wcomment
-Wcomments
Warn whenever a comment-start sequence
newline appears in a
-Wtrigraphs
Warn if any trigraphs are encountered. This option used to take effect only if
also specified, but now works independently. Warnings are not given for trigraphs within com-
ments, as they do not affect the meaning of the program.
-Wtraditional
Warn about certain constructs that behave differently in traditional and ISO C. Also warn about
ISO C constructs that have no traditional C equivalent, and problematic constructs which should
be avoided. Refer to Chapter 10 Traditional Mode.
-Wimport
Warn the first time
-Wundef
Warn whenever an identifier which is not a macro is encountered in an
. Such identifiers are replaced with zero.
defined
-Werror
Make all warnings into hard errors. Source code which triggers warnings will be rejected.
-Wsystem-headers
Issue warnings for code in system headers. These are normally unhelpful in finding bugs in your
own code, therefore suppressed. If you are responsible for the system library, you may want to
see them.
-w
Suppress all warnings, including those which GNU CPP issues by default.
to the list of directories to be searched for header files. Refer to Sec-
dir
. This is the same as specifying
file
. Note that many of the preprocessor's warnings are on by default and have
comment. (Both forms have the same effect.)
//
is used.
#import
are searched before the standard system include
-I
as the second non-option argument to
file
appears in a
comment, or whenever a backslash-
/*
/*
Chapter 12. Invocation
option. This defeats the
-I
-Wcomment
-trigraphs
directive, outside of
#if
to
-o
was

Advertisement

Table of Contents
loading

This manual is also suitable for:

Enterprise linux 3

Table of Contents