[all-commits] [llvm/llvm-project] 197182: [Driver] Fix `ToolChain::getCompilerRTPath()` to r...
Dan Liew via All-commits
all-commits at lists.llvm.org
Tue May 4 11:28:59 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 1971823ecb9eaa077554a5d268a44c7cb75eccce
https://github.com/llvm/llvm-project/commit/1971823ecb9eaa077554a5d268a44c7cb75eccce
Author: Dan Liew <dliew at apple.com>
Date: 2021-05-04 (Tue, 04 May 2021)
Changed paths:
M clang/lib/Driver/ToolChain.cpp
A clang/test/Driver/darwin-print-file-name.c
A clang/test/Driver/darwin-print-runtime-dir.c
Log Message:
-----------
[Driver] Fix `ToolChain::getCompilerRTPath()` to return the correct path on Apple platforms.
When the target triple was an Apple platform `ToolChain::getOSLibName()`
(called by `getCompilerRTPath()`) would return the full OS name
including the version number (e.g. `darwin20.3.0`). This is not correct
because the library directory for all Apple platforms is `darwin`.
This in turn caused
* `-print-runtime-dir` to return a non-existant path.
* `-print-file-name=<any compiler-rt library>` to return the filename
instead of the full path to the library.
Two regression tests are included.
rdar://77417317
Differential Revision: https://reviews.llvm.org/D101682
More information about the All-commits
mailing list