brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.9 KiB · 9f79fb1 Raw
47 lines · plain
1// REQUIRES: crash-recovery2// File path separator differences.3// UNSUPPORTED: system-windows4 5// RUN: rm -rf %t6// RUN: mkdir -p %t/i %t/m %t7// RUN: cp -R %S/Inputs/crash-recovery/Frameworks %t/i/8// RUN: mkdir -p %t/i/Frameworks/A.framework/Frameworks9// RUN: ln -s ../../B.framework %t/i/Frameworks/A.framework/Frameworks/B.framework10 11// RUN: env FORCE_CLANG_DIAGNOSTICS_CRASH= TMPDIR=%t TEMP=%t TMP=%t \12// RUN: not %clang -nostdinc -fsyntax-only %s \13// RUN:     -F %/t/i/Frameworks -fmodules \14// RUN:     -fmodules-cache-path=%t/m/ 2>&1 | FileCheck %s15 16// RUN: FileCheck --check-prefix=CHECKYAML %s -input-file \17// RUN:         %t/crash-vfs-*.cache/vfs/vfs.yaml18// RUN: find %t/crash-vfs-*.cache/vfs | \19// RUN:   grep "B.framework/Headers/B.h" | count 120 21// CHECK: Preprocessed source(s) and associated run script(s) are located at:22// CHECK-NEXT: note: diagnostic msg: {{.*}}.m23// CHECK-NEXT: note: diagnostic msg: {{.*}}.cache24 25// CHECKYAML:      'type': 'directory',26// CHECKYAML:      'name': "/[[PATH:.*]]/i/Frameworks/B.framework/Headers",27// CHECKYAML-NEXT:      'contents': [28// CHECKYAML-NEXT:        {29// CHECKYAML-NEXT:          'type': 'file',30// CHECKYAML-NEXT:          'name': "B.h",31// CHECKYAML-NEXT:          'external-contents': "/[[PATH]]/i/Frameworks/B.framework/Headers/B.h"32 33@import I;34 35// Run the reproducer script - regular exit code is enough to test it works. The36// intent here is to guarantee that the collect umbrella headers into the VFS37// can be used, testing that vfs::recursive_directory_iterator is used correctly38// Make sure to erase the include paths used to build the modules to guarantee39// that the VFS overlay won't fallback to use it. Also wipe out the module cache40// to force header search.41//42// RUN: cd %t43// RUN: rm -rf i44// RUN: rm -rf crash-vfs-umbrella-*.cache/modules/*45// RUN: chmod 755 crash-vfs-*.sh46// RUN: bash ./crash-vfs-*.sh47