[clang] Fix --print-libgcc-file-name on Darwin platforms (PR #98325)
Louis Dionne via cfe-commits
cfe-commits at lists.llvm.org
Wed Jul 10 07:40:51 PDT 2024
================
@@ -2271,6 +2271,12 @@ bool Driver::HandleImmediateArgs(const Compilation &C) {
if (C.getArgs().hasArg(options::OPT_print_libgcc_file_name)) {
ToolChain::RuntimeLibType RLT = TC.GetRuntimeLibType(C.getArgs());
const llvm::Triple Triple(TC.ComputeEffectiveClangTriple(C.getArgs()));
+ // The 'Darwin' toolchain is initialized only when its arguments are
----------------
ldionne wrote:
Could we do the same thing but move it way up above so that we initialize it early? I think the same bug exists with `-print-runtime-dir` (line 2232 above).
https://github.com/llvm/llvm-project/pull/98325
More information about the cfe-commits
mailing list