| 1 |
// Clang on MacOS can find libc++ living beside the installed compiler. |
| 2 |
// This test makes sure our libTooling-based tools emulate this properly with |
| 3 |
// fixed compilation database. |
| 4 |
// |
| 5 |
// RUN: rm -rf %t |
| 6 |
// RUN: mkdir %t |
| 7 |
// |
| 8 |
// Install the mock libc++ (simulates the libc++ directory structure). |
| 9 |
// RUN: cp -r %S/Inputs/mock-libcxx %t/ |
| 10 |
// |
| 11 |
// RUN: cp clang-check %t/mock-libcxx/bin/ |
| 12 |
// RUN: cp %s %t/test.cpp |
| 13 |
// RUN: "%t/mock-libcxx/bin/clang-check" -p %t %t/test.cpp -- \ |
| 14 |
// RUN: -stdlib=libc++ -target x86_64-apple-darwin \ |
| 15 |
// RUN: -ccc-install-dir %t/mock-libcxx/bin |
| 16 |
// |
| 17 |
// ^ -ccc-install-dir passed to unbreak tests on *BSD where |
| 18 |
// getMainExecutable() relies on real argv[0] being passed |
| 19 |
// |
| 20 |
// UNSUPPORTED: enable_shared |
| 21 |
#include <mock_vector> |
| 22 |
vector v; |