[flang-commits] [clang] [flang] [flang][driver] Support Makefile dependency generation (PR #209379)

Thirumalai Shaktivel via flang-commits flang-commits at lists.llvm.org
Mon Jul 20 02:43:10 PDT 2026


================
@@ -18,6 +19,25 @@ namespace clang {
 /// Only the characters '$', '#', ' ', '\t' are quoted.
 void quoteMakeTarget(StringRef Target, SmallVectorImpl<char> &Res);
 
+/// DependencyOutputFormat - Format for the compiler dependency file.
+enum class DependencyOutputFormat { Make, NMake };
+
+/// Write Make-style dependency output to the output stream, in the form:
+///   target1 target2 ...: prereq1 prereq2 ...
+///
+/// \param Targets The targets, already quoted for Make via quoteMakeTarget().
+/// \param Files The prerequisites; each is escaped for \p Format when written.
+/// \param Format Escape prerequisites for GNU Make or NMake.
+/// \param PhonyTargets If true, also emit an empty "prereq:" line for each
+///   prerequisite (except \p InputFileIndex), so later deleting a prerequisite
+///   doesn't break the build.
+/// \param InputFileIndex Index in \p Files of the main input, skipped above.
----------------
Thirumalai-Shaktivel wrote:

Meanings, "Skipped for the PhonyTargets". I have updated the file as well.

https://github.com/llvm/llvm-project/pull/209379


More information about the flang-commits mailing list