[C++] Re-generate ninja file when a file is added/removed
With this change, we store the results of file list related
commands in .kati_stamp. If one of them has been changed,
we re-generate ninja file.
Currently, this check is slow. We need to check the timestamp
of directories first like what we are doing for $(wildcard).
diff --git a/strutil.h b/strutil.h
index 848fc42..16f1f1e 100644
--- a/strutil.h
+++ b/strutil.h
@@ -87,6 +87,8 @@
bool HasSuffix(StringPiece str, StringPiece suffix);
+bool HasWord(StringPiece str, StringPiece w);
+
StringPiece TrimSuffix(StringPiece str, StringPiece suffix);
class Pattern {
@@ -130,4 +132,8 @@
// From http://www.gnu.org/software/make/manual/make.html#Features
StringPiece TrimLeadingCurdir(StringPiece s);
+void FormatForCommandSubstitution(string* s);
+
+string SortWordsInString(StringPiece s);
+
#endif // STRUTIL_H_