1 @c Copyright (c) 1999, 2000, 2001, 2002, 2004
2 @c Free Software Foundation, Inc.
3 @c This is part of the CPP and GCC manuals.
4 @c For copying conditions, see the file gcc.texi.
6 @c ---------------------------------------------------------------------
7 @c Environment variables affecting the preprocessor
8 @c ---------------------------------------------------------------------
10 @c If this file is included with the flag ``cppmanual'' set, it is
11 @c formatted for inclusion in the CPP manual; otherwise the main GCC manual.
16 @itemx CPLUS_INCLUDE_PATH
17 Each variable's value is a list of directories separated by a special
18 character, much like @env{PATH}, in which to look for header files.
19 The special character, @code{PATH_SEPARATOR}, is target-dependent and
20 determined at GCC build time. For Microsoft Windows-based targets it is a
21 semicolon, and for almost all other targets it is a colon.
23 @env{CPATH} specifies a list of directories to be searched as if
24 specified with @option{-I}, but after any paths given with @option{-I}
25 options on the command line. This environment variable is used
26 regardless of which language is being preprocessed.
28 The remaining environment variables apply only when preprocessing the
29 particular language indicated. Each specifies a list of directories
30 to be searched as if specified with @option{-isystem}, but after any
31 paths given with @option{-isystem} options on the command line.
33 In all these variables, an empty element instructs the compiler to
34 search its current working directory. Empty elements can appear at the
35 beginning or end of a path. For instance, if the value of
36 @env{CPATH} is @code{:/special/include}, that has the same
37 effect as @samp{@w{-I. -I/special/include}}.
41 See also @ref{Search Path}.
43 @c man begin ENVIRONMENT
45 @item DEPENDENCIES_OUTPUT
46 @cindex dependencies for make as output
47 If this variable is set, its value specifies how to output
48 dependencies for Make based on the non-system header files processed
49 by the compiler. System header files are ignored in the dependency
52 The value of @env{DEPENDENCIES_OUTPUT} can be just a file name, in
53 which case the Make rules are written to that file, guessing the target
54 name from the source file name. Or the value can have the form
55 @samp{@var{file} @var{target}}, in which case the rules are written to
56 file @var{file} using @var{target} as the target name.
58 In other words, this environment variable is equivalent to combining
59 the options @option{-MM} and @option{-MF}
64 (@pxref{Preprocessor Options}),
66 with an optional @option{-MT} switch too.
68 @item SUNPRO_DEPENDENCIES
69 @cindex dependencies for make as output
70 This variable is the same as @env{DEPENDENCIES_OUTPUT} (see above),
71 except that system header files are not ignored, so it implies
72 @option{-M} rather than @option{-MM}. However, the dependence on the
73 main input file is omitted.
78 @xref{Preprocessor Options}.