| 1 |
// REQUIRES: system-windows |
| 2 |
|
| 3 |
// RUN: rm -rf %t.dir |
| 4 |
// RUN: mkdir -p %t.dir/subdir |
| 5 |
// RUN: echo > %t.dir/subdir/x.h |
| 6 |
// RUN: cp %s %t.dir/test.c |
| 7 |
// RUN: cd %t.dir |
| 8 |
|
| 9 |
// RUN: %clang -MD -MF - %t.dir/test.c -fsyntax-only -I %t.dir/subdir | FileCheck %s |
| 10 |
// CHECK: test.o: |
| 11 |
// CHECK-NEXT: \test.c |
| 12 |
// CHECK-NEXT: \SubDir\X.h |
| 13 |
// File x.h must appear only once (case insensitive check). |
| 14 |
// CHECK-NOT: {{\\|/}}{{x|X}}.{{h|H}} |
| 15 |
|
| 16 |
// Include x.h several times, with different casing and separators. |
| 17 |
// Since all paths are passed to clang as absolute, all dependencies are absolute paths. |
| 18 |
// We expect the output dependencies to contain only one line for file x.h |
| 19 |
|
| 20 |
// Test case sensitivity. |
| 21 |
#include "SubDir/X.h" |
| 22 |
#include "subdir/x.h" |
| 23 |
|
| 24 |
// Test separator sensitivity: |
| 25 |
// clang internally concatenates x.h using the Windows native separator. |
| 26 |
#include <x.h> |
| 27 |
|