r251459 - Minor fix in ToolChainTest.cpp to allow user defined GCC toolchain.
Samuel Antao via cfe-commits
cfe-commits at lists.llvm.org
Tue Oct 27 15:20:26 PDT 2015
Author: sfantao
Date: Tue Oct 27 17:20:26 2015
New Revision: 251459
URL: http://llvm.org/viewvc/llvm-project?rev=251459&view=rev
Log:
Minor fix in ToolChainTest.cpp to allow user defined GCC toolchain.
If the user configured clang with a custom GCC toolchain that will take precedence on what the ToolChainTest.cpp expects to evaluate.
This is fixed here by passing --gcc-toolchain= to the driver, in order to override any user defined GCC toolchain.
Modified:
cfe/trunk/unittests/Driver/ToolChainTest.cpp
Modified: cfe/trunk/unittests/Driver/ToolChainTest.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/unittests/Driver/ToolChainTest.cpp?rev=251459&r1=251458&r2=251459&view=diff
==============================================================================
--- cfe/trunk/unittests/Driver/ToolChainTest.cpp (original)
+++ cfe/trunk/unittests/Driver/ToolChainTest.cpp Tue Oct 27 17:20:26 2015
@@ -58,8 +58,8 @@ TEST(ToolChainTest, VFSGCCInstallation)
InMemoryFileSystem->addFile(Path, 0,
llvm::MemoryBuffer::getMemBuffer("\n"));
- std::unique_ptr<Compilation> C(
- TheDriver.BuildCompilation({"-fsyntax-only", "foo.cpp"}));
+ std::unique_ptr<Compilation> C(TheDriver.BuildCompilation(
+ {"-fsyntax-only", "--gcc-toolchain=", "foo.cpp"}));
std::string S;
{
@@ -97,8 +97,8 @@ TEST(ToolChainTest, VFSGCCInstallationRe
InMemoryFileSystem->addFile(Path, 0,
llvm::MemoryBuffer::getMemBuffer("\n"));
- std::unique_ptr<Compilation> C(
- TheDriver.BuildCompilation({"-fsyntax-only", "foo.cpp"}));
+ std::unique_ptr<Compilation> C(TheDriver.BuildCompilation(
+ {"-fsyntax-only", "--gcc-toolchain=", "foo.cpp"}));
std::string S;
{
More information about the cfe-commits
mailing list