[flang-commits] [clang] [flang] [flang] Do not hardcode "flang" in the driver (PR #200438)
Tarun Prabhu via flang-commits
flang-commits at lists.llvm.org
Mon Jun 15 15:48:27 PDT 2026
================
@@ -1320,7 +1320,18 @@ void Flang::ConstructJob(Compilation &C, const JobAction &JA,
Input.getInputArg().renderAsInput(Args, CmdArgs);
}
- const char *Exec = Args.MakeArgString(D.GetProgramPath("flang", TC));
+ // Handle "clang --driver-mode=flang" case
+ bool isClangDriverWithFlangMode = false;
+ if (D.Name.find("clang") != std::string_view::npos) {
----------------
tarunprabhu wrote:
Thanks. In principle, if `clang --driver-mode=flang` works, then `flang --driver-mode=gcc` should too. I think it is ok to defer this to a different PR. I don't know how widely the `--driver-mode` option is used in practice, even with clang.
https://github.com/llvm/llvm-project/pull/200438
More information about the flang-commits
mailing list