[all-commits] [llvm/llvm-project] 2db1f7: Restore functionality of --sysroot on FreeBSD afte...
Dimitry Andric via All-commits
all-commits at lists.llvm.org
Wed Feb 19 04:30:48 PST 2020
Branch: refs/heads/release/10.x
Home: https://github.com/llvm/llvm-project
Commit: 2db1f7f59a276923138d2115dd7bcc5e70479b9c
https://github.com/llvm/llvm-project/commit/2db1f7f59a276923138d2115dd7bcc5e70479b9c
Author: Dimitry Andric <dimitry at andric.com>
Date: 2020-02-19 (Wed, 19 Feb 2020)
Changed paths:
M clang/lib/Driver/ToolChains/FreeBSD.cpp
M clang/lib/Driver/ToolChains/FreeBSD.h
Log Message:
-----------
Restore functionality of --sysroot on FreeBSD after b18cb9c47
After b18cb9c47, clang would sometimes prefer the host C++ includes
(e.g. in /usr/include/c++/v1) before those specified via --sysroot.
While this behavior may be desirable on Linux, it is not so on FreeBSD,
where we make extensive use of --sysroot during the build of the base
system. In that case, clang must *not* search outside the sysroot,
except for its own internal headers.
Add an override addLibCxxIncludePaths() to restore the old behavior,
which is to simply append /usr/include/c++/v1 to the specified sysroot.
While here, apply clang-format to the FreeBSD specific toolchain files.
Fixes PR44923.
(cherry picked from commit 62654cab7e654384ba503d6b62b1054cde19a553)
More information about the All-commits
mailing list