aboutsummaryrefslogtreecommitdiff
path: root/gcc/cpp.1
diff options
context:
space:
mode:
authorJoseph Myers <jsm28@cam.ac.uk>2001-01-12 18:51:27 +0000
committerJoseph Myers <jsm28@gcc.gnu.org>2001-01-12 18:51:27 +0000
commit5490d6045a06a882ff31eacb639404dc0c9ef89a (patch)
treefb4bf44c735f9abf9e38f7f9106636f36c297176 /gcc/cpp.1
parentbedc7537144d97956664af172c6d6180d4467afc (diff)
downloadgcc-5490d6045a06a882ff31eacb639404dc0c9ef89a.zip
gcc-5490d6045a06a882ff31eacb639404dc0c9ef89a.tar.gz
gcc-5490d6045a06a882ff31eacb639404dc0c9ef89a.tar.bz2
cpp.texi, [...]: Consistently refer to ISO C instead of ANSI C.
* cpp.texi, extend.texi, gcc.texi, install.texi, invoke.texi, tm.texi: Consistently refer to ISO C instead of ANSI C. Refer to -std options alongside references to -ansi. Update some documentation for C99. * cpp.1: Regenerate. From-SVN: r38956
Diffstat (limited to 'gcc/cpp.1')
-rw-r--r--gcc/cpp.1111
1 files changed, 78 insertions, 33 deletions
diff --git a/gcc/cpp.1 b/gcc/cpp.1
index 6f5281a..aa00123 100644
--- a/gcc/cpp.1
+++ b/gcc/cpp.1
@@ -1,5 +1,5 @@
.\" Automatically generated by Pod::Man version 1.1
-.\" Wed Jan 3 20:06:19 2001
+.\" Fri Jan 12 18:47:56 2001
.\"
.\" Standard preamble:
.\" ======================================================================
@@ -138,7 +138,7 @@
.\" ======================================================================
.\"
.IX Title "CPP 1"
-.TH CPP 1 "gcc-2.97" "2001-01-03" "GNU"
+.TH CPP 1 "gcc-2.97" "2001-01-12" "GNU"
.UC
.SH "NAME"
cpp \- The C Preprocessor
@@ -149,7 +149,8 @@ cpp [\fB\-P\fR] [\fB\-C\fR] [\fB\-gcc\fR] [\fB\-traditional\fR]
[\fB\-W\fR\fIwarn\fR...] [\fB\-I\fR\fIdir\fR...]
[\fB\-D\fR\fImacro\fR[=\fIdefn\fR]...] [\fB\-U\fR\fImacro\fR]
[\fB\-A\fR\fIpredicate\fR(\fIanswer\fR)]
- [\fB\-M\fR|\fB\-MM\fR|\fB\-MD\fR|\fB\-MMD\fR [\fB\-MG\fR]]
+ [\fB\-M\fR|\fB\-MM\fR][\fB\-MG\fR][\fB\-MF\fR\fIfilename\fR]
+ [\fB\-MP\fR][\fB\-MQ\fR\fItarget\fR...][\fB\-MT\fR\fItarget\fR...]
[\fB\-x\fR \fIlanguage\fR] [\fB\-std=\fR\fIstandard\fR]
\fIinfile\fR \fIoutfile\fR
.PP
@@ -417,6 +418,9 @@ the current one and which are searched after.
Do not search the standard system directories for header files.
Only the directories you have specified with \fB\-I\fR options
(and the current directory, if appropriate) are searched.
+.Sp
+By using both \fB\-nostdinc\fR and \fB\-I-\fR, you can limit the include-file
+search path to only those directories you specify explicitly.
.Ip "\fB\-nostdinc++\fR" 4
.IX Item "-nostdinc++"
Do not search for header files in the \*(C+\-specific standard directories,
@@ -442,11 +446,17 @@ may need to use the shell's quoting syntax to protect characters such as
spaces that have a meaning in the shell syntax. If you use more than
one \fB\-D\fR for the same \fIname\fR, the rightmost definition takes
effect.
+.Sp
+Any \fB\-D\fR and \fB\-U\fR options on the command line are processed in
+order, and always before \fB\-imacros\fR \fIfile\fR, regardless of the
+order in which they are written.
.Ip "\fB\-U\fR \fIname\fR" 4
.IX Item "-U name"
-Do not predefine \fIname\fR. If both \fB\-U\fR and \fB\-D\fR are
-specified for one name, whichever one appears later on the command line
-wins.
+Do not predefine \fIname\fR.
+.Sp
+Any \fB\-D\fR and \fB\-U\fR options on the command line are processed in
+order, and always before \fB\-imacros\fR \fIfile\fR, regardless of the
+order in which they are written.
.Ip "\fB\-undef\fR" 4
.IX Item "-undef"
Do not predefine any nonstandard macros.
@@ -493,42 +503,77 @@ Like \fB\-dD\fR, but emit only the macro names, not their expansions.
.IX Item "-dI"
Output \fB#include\fR directives in addition to the result of
preprocessing.
-.Ip "\fB\-M [\-MG]\fR" 4
-.IX Item "-M [-MG]"
+.Ip "\fB\-M\fR" 4
+.IX Item "-M"
Instead of outputting the result of preprocessing, output a rule
suitable for \f(CW\*(C`make\*(C'\fR describing the dependencies of the main source
file. The preprocessor outputs one \f(CW\*(C`make\*(C'\fR rule containing the
object file name for that source file, a colon, and the names of all the
included files. If there are many included files then the rule is split
into several lines using \fB\e\fR\-newline.
-.Sp
-\&\fB\-MG\fR says to treat missing header files as generated files and
-assume they live in the same directory as the source file. It must be
-specified in addition to \fB\-M\fR.
-.Sp
-This feature is used in automatic updating of makefiles.
-.Ip "\fB\-MM [\-MG]\fR" 4
-.IX Item "-MM [-MG]"
-Like \fB\-M\fR but mention only the files included with \fB#include
+.Ip "\fB\-MM\fR" 4
+.IX Item "-MM"
+Like \fB\-M\fR, but mention only the files included with \fB#include
"\fR\fIfile\fR\fB"\fR. System header files included with \fB#include
<\fR\fIfile\fR\fB>\fR are omitted.
-.Ip "\fB\-MD\fR \fIfile\fR" 4
-.IX Item "-MD file"
-Like \fB\-M\fR but the dependency information is written to \fIfile\fR.
-This is in addition to compiling the file as specified \-\-\- \fB\-MD\fR
-does not inhibit ordinary compilation the way \fB\-M\fR does.
+.Ip "\fB\-MF\fR \fIfile\fR" 4
+.IX Item "-MF file"
+When used with \fB\-M\fR or \fB\-MM\fR, specifies a file to write the
+dependencies to. This allows the preprocessor to write the preprocessed
+file to stdout normally. If no \fB\-MF\fR switch is given, \s-1CPP\s0 sends
+the rules to stdout and suppresses normal preprocessed output.
+.Ip "\fB\-MG\fR" 4
+.IX Item "-MG"
+When used with \fB\-M\fR or \fB\-MM\fR, \fB\-MG\fR says to treat missing
+header files as generated files and assume they live in the same
+directory as the source file. It suppresses preprocessed output, as a
+missing header file is ordinarily an error.
+.Sp
+This feature is used in automatic updating of makefiles.
+.Ip "\fB\-MP\fR" 4
+.IX Item "-MP"
+This option instructs \s-1CPP\s0 to add a phony target for each dependency
+other than the main file, causing each to depend on nothing. These
+dummy rules work around errors \f(CW\*(C`make\*(C'\fR gives if you remove header
+files without updating the \f(CW\*(C`Makefile\*(C'\fR to match.
+.Sp
+This is typical output:\-
+.Sp
+.Vb 1
+\& /tmp/test.o: /tmp/test.c /tmp/test.h
+.Ve
+.Vb 1
+\& /tmp/test.h:
+.Ve
+.Ip "\fB\-MQ\fR \fItarget\fR" 4
+.IX Item "-MQ target"
+.PD 0
+.Ip "\fB\-MT\fR \fItarget\fR" 4
+.IX Item "-MT target"
+.PD
+By default \s-1CPP\s0 uses the main file name, including any path, and appends
+the object suffix, normally ``.o'', to it to obtain the name of the
+target for dependency generation. With \fB\-MT\fR you can specify a
+target yourself, overriding the default one.
+.Sp
+If you want multiple targets, you can specify them as a single argument
+to \fB\-MT\fR, or use multiple \fB\-MT\fR options.
.Sp
-When invoking \f(CW\*(C`gcc\*(C'\fR, do not specify the \fIfile\fR argument.
-\&\f(CW\*(C`gcc\*(C'\fR will create file names made by replacing \*(L".c\*(R" with \*(L".d\*(R" at
-the end of the input file names.
+The targets you specify are output in the order they appear on the
+command line. \fB\-MQ\fR is identical to \fB\-MT\fR, except that the
+target name is quoted for Make, but with \fB\-MT\fR it isn't. For
+example, \-MT '$(objpfx)foo.o' gives
.Sp
-In Mach, you can use the utility \f(CW\*(C`md\*(C'\fR to merge multiple dependency
-files into a single dependency file suitable for using with the
-\&\fBmake\fR command.
-.Ip "\fB\-MMD\fR \fIfile\fR" 4
-.IX Item "-MMD file"
-Like \fB\-MD\fR except mention only user header files, not system
-header files.
+.Vb 1
+\& $(objpfx)foo.o: /tmp/foo.c
+.Ve
+but \-MQ '$(objpfx)foo.o' gives
+.Sp
+.Vb 1
+\& $$(objpfx)foo.o: /tmp/foo.c
+.Ve
+The default target is automatically quoted, as if it were given with
+\&\fB\-MQ\fR.
.Ip "\fB\-H\fR" 4
.IX Item "-H"
Print the name of each header file used, in addition to other normal
@@ -668,7 +713,7 @@ common extension.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
Copyright (c) 1987, 1989, 1991, 1992, 1993, 1994, 1995, 1996,
-1997, 1998, 1999, 2000
+1997, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
.PP
Permission is granted to make and distribute verbatim copies of