[cfe-dev] Cleaning up the clang::driver::toolchains::Linux mess?
David Chisnall
csdavec at swan.ac.uk
Wed Jun 15 01:50:19 PDT 2011
On 14 Jun 2011, at 19:09, Anders Kaseorg wrote:
> Not relying on GCC would mean that I
> don’t need to have any parts of GCC installed to use clang
The problem with this is that GCC has a habit of assimilating vaguely-related projects and Linux distributions let it get away with this by not splitting them up again for packaging. For example, the GCC libstdc++ and libobjc do not support building outside of the GCC tree, but they are not specific to GCC - they can be used by other compilers.
The BSDs (including OS X) provide their own build system for components like these, so that they can be built and upgraded independently of GCC. Linux distributions tend to go the lazy route and just have one big-fat gcc package that includes a huge mess of stuff that's nothing to do with the compiler (yet, oddly, the do tend to compile the various GCC front ends in different packages).
If you use a system maintained by people who understand the difference between a compiler, a header, and a library, then you can use clang without GCC. If you use a system maintained by people who only install compiler-independent libraries and headers when you happen to install a compiler, and place these headers and libraries in a package-version-dependent location that is hard-coded into the compiler, then you are going to have problems.
David
--
This email complies with ISO 3103
More information about the cfe-dev
mailing list