1 // RUN: rm -rf %t 2 // RUN: split-file %s %t 3 4 // Check that with a sufficiently new SDK not searching for module maps in subdirectories. 5 6 // New SDK. 7 // RUN: %clang -target x86_64-apple-macos10.13 -isysroot %t/MacOSX15.0.sdk -fmodules %t/test.c -### 2>&1 \ 8 // RUN: | FileCheck --check-prefix=NO-SUBDIRECTORIES %t/test.c 9 // Old SDK. 10 // RUN: %clang -target x86_64-apple-macos10.13 -isysroot %t/MacOSX14.0.sdk -fmodules %t/test.c -### 2>&1 \ 11 // RUN: | FileCheck --check-prefix=SEARCH-SUBDIRECTORIES %t/test.c 12 // Non-Darwin platform. 13 // RUN: %clang -target i386-unknown-linux -isysroot %t/MacOSX15.0.sdk -fmodules %t/test.c -### 2>&1 \ 14 // RUN: | FileCheck --check-prefix=SEARCH-SUBDIRECTORIES %t/test.c 15 // New SDK overriding the default. 16 // RUN: %clang -target x86_64-apple-macos10.13 -isysroot %t/MacOSX15.0.sdk -fmodules %t/test.c -fmodulemap-allow-subdirectory-search -### 2>&1 \ 17 // RUN: | FileCheck --check-prefix=SEARCH-SUBDIRECTORIES %t/test.c 18 19 //--- test.c 20 // NO-SUBDIRECTORIES: "-fno-modulemap-allow-subdirectory-search" 21 // SEARCH-SUBDIRECTORIES-NOT: "-fno-modulemap-allow-subdirectory-search" 22 23 //--- MacOSX15.0.sdk/SDKSettings.json 24 {"Version":"15.0", "MaximumDeploymentTarget": "15.0.99"} 25 26 //--- MacOSX14.0.sdk/SDKSettings.json 27 {"Version":"14.0", "MaximumDeploymentTarget": "14.0.99"} 28