aboutsummaryrefslogtreecommitdiff
path: root/libcpp/include
diff options
context:
space:
mode:
authorNathan Sidwell <nathan@acm.org>2019-05-07 12:39:59 +0000
committerNathan Sidwell <nathan@gcc.gnu.org>2019-05-07 12:39:59 +0000
commitd7b6aee8cd346328b6f22fc415ffc28b9cf8a285 (patch)
treed5215a9bd23a4458a51a91a6c508044421f4bb88 /libcpp/include
parent7664eeb700d9e95339f04a1c308a095b53d7a5fb (diff)
downloadgcc-d7b6aee8cd346328b6f22fc415ffc28b9cf8a285.zip
gcc-d7b6aee8cd346328b6f22fc415ffc28b9cf8a285.tar.gz
gcc-d7b6aee8cd346328b6f22fc415ffc28b9cf8a285.tar.bz2
[libcpp] Reimplement mkdeps data structures
https://gcc.gnu.org/ml/gcc-patches/2019-05/msg00293.html * include/mkdeps.h (deps_write): Add PHONY arg. (deps_phony_targets): Delete. * init.c (cpp_finish): Just call deps_write. * mkdeps.c (struct mkdeps): Add local vector class. Reimplement vector handling. (munge): Munge to static buffer. (apply_vpath): Adjust vector handling. (deps_init, deps_free): Use new, delete. (deps_add_target): Do not munge here. Record quoting low water mark. (deps_add_dep): Do not munge here. (deps_add_vpath): Adjust vector handling. (make_write_name): New. Munge on demand here. (make_write_vec): New. (deps_phony_targets): Delete. (make_write): New. (deps_write): Forward to deps_Write. (deps_save, deps_restore): Adjust vector handling. From-SVN: r270943
Diffstat (limited to 'libcpp/include')
-rw-r--r--libcpp/include/mkdeps.h8
1 files changed, 1 insertions, 7 deletions
diff --git a/libcpp/include/mkdeps.h b/libcpp/include/mkdeps.h
index b0e3472..e0ac21f 100644
--- a/libcpp/include/mkdeps.h
+++ b/libcpp/include/mkdeps.h
@@ -57,7 +57,7 @@ extern void deps_add_dep (struct mkdeps *, const char *);
/* Write out a deps buffer to a specified file. The third argument
is the number of columns to word-wrap at (0 means don't wrap). */
-extern void deps_write (const struct mkdeps *, FILE *, unsigned int);
+extern void deps_write (const struct mkdeps *, FILE *, bool, unsigned int);
/* Write out a deps buffer to a file, in a form that can be read back
with deps_restore. Returns nonzero on error, in which case the
@@ -70,10 +70,4 @@ extern int deps_save (struct mkdeps *, FILE *);
in which case that filename is skipped. */
extern int deps_restore (struct mkdeps *, FILE *, const char *);
-/* For each dependency *except the first*, emit a dummy rule for that
- file, causing it to depend on nothing. This is used to work around
- the intermediate-file deletion misfeature in Make, in some
- automatic dependency schemes. */
-extern void deps_phony_targets (const struct mkdeps *, FILE *);
-
#endif /* ! LIBCPP_MKDEPS_H */