[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:42:06 PDT 2026
================
@@ -236,6 +236,21 @@ is `ParseSyntaxOnlyAction`, which corresponds to `-fsyntax-only`. In other
words, `flang -fc1 <input-file>` is equivalent to `flang -fc1 -fsyntax-only
<input-file>`.
+## Dependency File Generation
+Flang can emit Makefile-style dependency rules with `-M`, `-MM`, `-MD` and
+`-MMD` (paired with `-MF`, `-MT` and `-MQ` to control the output file and the
+rule target).
+
+There is one behavioural difference to be aware of regarding module
+dependencies (the `.mod` files brought in by `use` statements):
----------------
Thirumalai-Shaktivel wrote:
It's between `-M`/`-MM` and `-MD`/`-MMD`
https://github.com/llvm/llvm-project/pull/209379
More information about the flang-commits
mailing list