[cfe-commits] r151889 - in /cfe/trunk/lib: Basic/Targets.cpp Frontend/InitHeaderSearch.cpp

David Chisnall csdavec at swan.ac.uk
Fri Mar 2 03:57:05 PST 2012


On 2 Mar 2012, at 11:25, Chandler Carruth wrote:

> If you're going to be touching Solaris header search logic, please factor it into the driver like the Linux header search logic. That requires a separate Solaris toolchain (if there isn't one already) and overriding some methods, but it should be straight forward. Both win32 and Linux are already factored so you can look at those as an example.

i asked you twice in IRC about this and didn't get any answer either time...

The gcc libraries are in the pattern:

/usr/gcc/{gcc_major}.{gcc_minor}/lib/gcc/{triple}/{gcc_major}.{gcc_minor}.{gcc_subminor}/[amd64/]

How do I use the GCC search logic to find things in this layout?  It seemed to be pretty Linux-specific, but I'd prefer to reuse it.

>> Unconditionally define __C99FEATURES__ when using C++ on Solaris.  This is a
>> (hopefully temporary) work around for libc++ exposing C99-but-not-C++98
>> features in C++98 mode.
> 
> Test case? Please don't commit without test cases.

I prefer not to commit meaningless tests.  I could check that __C99FEATURES__ is defined on Solaris, but that's not the important thing.  The important test is whether a file compiled with -stdlib=libc++ but not -std=c++0x can be compiled.  Depending on the contents of Solaris system headers and libc++ headers, this may or may not require __C99FEATURES__ to be defined.  It is not possible to test this on any system that does not have both the libc++ and Solaris headers installed.

All that adding a test for the __C99FEATURES__ macro would do is slow down execution of the test suite, without checking for anything meaningful.  

David





More information about the cfe-commits mailing list