| From 2f0413250e91c44b4e42a5334f00b7b937600076 Mon Sep 17 00:00:00 2001 |
| From: Matthias Vallentin <vallentin@icir.org> |
| Date: Wed, 5 Nov 2014 13:32:12 -0800 |
| Subject: Remove hard-coded /usr prefix on FreeBSD. |
| |
| The toolchain used to hardcode /usr/include/c++/v1 as default include |
| path on FreeBSD, which breaks because that path exists already and |
| contains an outdated set of standard library includes. |
| |
| The correct include path must be relative to the prefix, which this |
| patch adjusts. |
| --- |
| lib/Driver/ToolChains.cpp | 2 +- |
| 1 file changed, 1 insertion(+), 1 deletion(-) |
| |
| diff --git a/lib/Driver/ToolChains.cpp b/lib/Driver/ToolChains.cpp |
| index b46f69d..2309b2d 100644 |
| --- a/lib/Driver/ToolChains.cpp |
| +++ b/lib/Driver/ToolChains.cpp |
| @@ -2561,7 +2561,7 @@ void FreeBSD::AddClangCXXStdlibIncludeArgs(const ArgList &DriverArgs, |
| switch (GetCXXStdlibType(DriverArgs)) { |
| case ToolChain::CST_Libcxx: |
| addSystemInclude(DriverArgs, CC1Args, |
| - getDriver().SysRoot + "/usr/include/c++/v1"); |
| + getDriver().Dir + "/../include/c++/v1"); |
| break; |
| case ToolChain::CST_Libstdcxx: |
| addSystemInclude(DriverArgs, CC1Args, |
| -- |
| 2.1.2 |
| |