llvm-project/clang/lib/Driver
Chandler Carruth 7f8042c8f3 Find a better compromise with the default library search paths used by
Clang when linking and using a GCC installation from a GCC
cross-compiler.

This was desired already by two special case platforms (Android and
Mips), and turns out to be generally (if frustratingly) true. I've added
a substantial comment to the code clarifying the underlying assumptions
of doing actual cross compiles with Clang (or GCC for that matter!) and
help avoid further confusion here.

The end result is to realize that fully general form of PR12478 cannot
be resolved while we support existing cross-compiling GCC toolchains,
and linking with them (namely, linking against their libgcc and
libstdc++ installs). GCC installs these target libraries under
a target-specific prefix but one that may not be available within the
actual sysroot in use. When linking in this world, GCC works and Clang
should as well, but caveat emptor: DSOs from this tree must be
replicated and rpath-fixed to be found at runtime within the sysroot.

I've extended the cross compile test cases to cover these issues by
pointing them at a sysroot and actually checking the library search
paths.

llvm-svn: 187466
2013-07-31 00:37:07 +00:00
..
Action.cpp [Driver] Refactor clang driver to use LLVM's Option library 2013-06-14 17:17:23 +00:00
CC1AsOptions.cpp Option parsing tables: remove some unnecessary #defines 2013-07-17 16:54:06 +00:00
CMakeLists.txt [Driver] Refactor clang driver to use LLVM's Option library 2013-06-14 17:17:23 +00:00
Compilation.cpp Remove the -ccc-echo option that is now unused. 2013-07-23 17:58:53 +00:00
Driver.cpp Start keeping track of what work was done to detect a GCC installation 2013-07-30 17:57:09 +00:00
DriverOptions.cpp Option parsing tables: remove some unnecessary #defines 2013-07-17 16:54:06 +00:00
InputInfo.h [Driver] Remove the using namespace directives from headers 2013-06-17 13:59:19 +00:00
Job.cpp [Driver] Refactor clang driver to use LLVM's Option library 2013-06-14 17:17:23 +00:00
Makefile BUILD_ARCHIVE is the default for libraries, no need to set it. 2010-07-18 00:14:47 +00:00
Phases.cpp Sort all of Clang's files under 'lib', and fix up the broken headers 2012-12-04 09:13:33 +00:00
SanitizerArgs.h Add -fno-assume-sane-operator-new when building with MSan. 2013-06-20 10:49:46 +00:00
Tool.cpp Remove stray emacs mode markers in all these files that was causing emacs to 2010-12-31 17:31:54 +00:00
ToolChain.cpp [PowerPC] Support powerpc64le as a syntax-checking target. 2013-07-26 01:36:11 +00:00
ToolChains.cpp Find a better compromise with the default library search paths used by 2013-07-31 00:37:07 +00:00
ToolChains.h Start keeping track of what work was done to detect a GCC installation 2013-07-30 17:57:09 +00:00
Tools.cpp [PowerPC] Support powerpc64le as a syntax-checking target. 2013-07-26 01:36:11 +00:00
Tools.h [SystemZ] Add -march= command-line option 2013-07-19 16:51:51 +00:00
Types.cpp Use llvm::array_lengthof to replace sizeof(array)/sizeof(array[0]). 2013-07-15 03:38:40 +00:00
WindowsToolChain.cpp Remove PathV1.h use from WindowsToolChain.cpp. 2013-06-26 03:39:10 +00:00