Ticket #53194: patch-macports-libstdcxx.diff
File patch-macports-libstdcxx.diff, 1.8 KB (added by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez), 8 years ago) |
---|
-
tools/clang/lib/Frontend/InitHeaderSearch.cpp
old new 109 109 #if defined(LLVM_ON_WIN32) 110 110 return !Path.empty() && llvm::sys::path::is_separator(Path[0]); 111 111 #else 112 return llvm::sys::path::is_absolute(Path) ;112 return llvm::sys::path::is_absolute(Path) && Path.find("@@MACPORTS_GCC_INCLUDE_DIR@@")!=0; 113 113 #endif 114 114 } 115 115 … … 362 362 363 363 case llvm::Triple::ppc: 364 364 case llvm::Triple::ppc64: 365 AddGnuCPlusPlusIncludePaths("@@MACPORTS_GCC_INCLUDE_DIR@@", 366 "@@MACPORTS_HOST_NAME@@", "", "ppc64", 367 triple); 365 368 AddGnuCPlusPlusIncludePaths("/usr/include/c++/4.2.1", 366 369 "powerpc-apple-darwin10", "", "ppc64", 367 370 triple); … … 372 375 373 376 case llvm::Triple::x86: 374 377 case llvm::Triple::x86_64: 378 AddGnuCPlusPlusIncludePaths("@@MACPORTS_GCC_INCLUDE_DIR@@", 379 "@@MACPORTS_HOST_NAME@@", "i386", "", triple); 375 380 AddGnuCPlusPlusIncludePaths("/usr/include/c++/4.2.1", 376 381 "i686-apple-darwin10", "", "x86_64", triple); 377 382 AddGnuCPlusPlusIncludePaths("/usr/include/c++/4.0.0", -
tools/clang/lib/Driver/ToolChains.cpp
old new 746 746 // platforms we care about it was -lstdc++.6, so we search for that 747 747 // explicitly if we can't see an obvious -lstdc++ candidate. 748 748 749 if (getVFS().exists("@@MACPORTS_libstdc++@@")) { 750 CmdArgs.push_back("@@MACPORTS_libstdc++@@"); 751 return; 752 } 753 749 754 // Check in the sysroot first. 750 755 if (const Arg *A = Args.getLastArg(options::OPT_isysroot)) { 751 756 SmallString<128> P(A->getValue());