Page MenuHomePhabricator

[lldb][dotest] Improve libc++ detection

Authored by rupprecht on Dec 10 2019, 4:53 PM.



The test logic for running libc++ tests only looks to see if /usr/include/c++/v1 exists. This adds a fallback for including libc++ tests as long as $(CC) -stdlib=libc++ works.

Diff Detail

Event Timeline

rupprecht created this revision.Dec 10 2019, 4:53 PM
Herald added a project: Restricted Project. · View Herald Transcript

Build result: pass - 60689 tests passed, 0 failed and 726 were skipped.

Log files: console-log.txt, CMakeCache.txt

labath accepted this revision.Dec 11 2019, 4:05 AM

This seems ok. The reason these checks are written this way is because we used to have the xcode build which bypassed cmake and lit, so this was the only place to implement that centrally. Nowadays, we could probably come up with a simpler way to do these things, but I don't have a clear idea on how to do that yet...

This revision is now accepted and ready to land.Dec 11 2019, 4:05 AM
This revision was automatically updated to reflect the committed changes.
rupprecht marked an inline comment as done.Dec 11 2019, 2:23 PM
rupprecht added inline comments.

FYI, the check didn't work because this isn't exercising anything in libc++, it really only checks that -stdlib=libc++ is a valid compiler flag. 786b6db8e6fd87fb82f2ad3e94e20c5c9cf9c4e4 fixes this by adding a libc++ include, which fails the command if libc++ is not installed where clang can find it.