summaryrefslogtreecommitdiff
path: root/gcc/cpp.texi
diff options
context:
space:
mode:
authorNathan Sidwell <nathan@codesourcery.com>2000-06-30 09:47:49 +0000
committerNathan Sidwell <nathan@gcc.gnu.org>2000-06-30 09:47:49 +0000
commitf3f751adcb318b6f5183f94686dc108715981e6a (patch)
tree4970a3469f1e57aa1f8e1516bdd8be5ca7391d38 /gcc/cpp.texi
parent34f9943ef73797e5db1039d888785b0bc5f220e0 (diff)
downloadgcc-f3f751adcb318b6f5183f94686dc108715981e6a.tar.gz
cpp.texi: Document #pragma GCC dependency
* cpp.texi: Document #pragma GCC dependency * cppfiles.c (open_include_file): Set date to unknown. (_cpp_compare_file_date): New function. (read_include_file): Set file date. * cpphash.h (struct include_file): Add date member. (_cpp_compare_file_date): Prototype. * cpplib.c (parse_include): Add trail parameter. Adjust. (do_include): Adjust parse_include call. (do_import): Likewise. (do_include_next): Likewise. (gcc_pragmas): Add dependency pragma. (do_pragma_dependancy): New pragma. From-SVN: r34808
Diffstat (limited to 'gcc/cpp.texi')
-rw-r--r--gcc/cpp.texi14
1 files changed, 14 insertions, 0 deletions
diff --git a/gcc/cpp.texi b/gcc/cpp.texi
index 6413eec5420..47647025bcc 100644
--- a/gcc/cpp.texi
+++ b/gcc/cpp.texi
@@ -2664,6 +2664,20 @@ the text is ignored and this directive has no effect. Typically
@samp{#ident} is only used in header files supplied with those systems
where it is meaningful.
+@findex #pragma GCC dependency
+The @samp{#pragma GCC dependency} allows you to check the relative dates
+of the current file and another file. If the other file is more
+recent than the current file, a warning is issued. This is useful if the
+include file is derived from the other file, and should be regenerated.
+The other file is searched for using the normal include search path.
+Optional trailing text can be used to give more information in the
+warning message.
+
+@smallexample
+#pragma GCC dependency "parse.y"
+#pragma GCC dependency "/usr/include/time.h" rerun /path/to/fixincludes
+@end smallexample
+
@node Output, Invocation, Other Directives, Top
@section C Preprocessor Output