|
| 1 | +// Test the output of -print-target-triple on Darwin. |
| 2 | +// See https://github.com/llvm/llvm-project/issues/61762 |
| 3 | + |
| 4 | +// |
| 5 | +// All platforms |
| 6 | +// |
| 7 | + |
| 8 | +// RUN: %clang -print-target-triple \ |
| 9 | +// RUN: --target=x86_64-apple-macos -mmacos-version-min=15 \ |
| 10 | +// RUN: -resource-dir=%S/Inputs/resource_dir 2>&1 \ |
| 11 | +// RUN: | FileCheck --check-prefix=CHECK-CLANGRT-MACOS %s |
| 12 | +// CHECK-CLANGRT-MACOS: x86_64-apple-macosx15.0.0 |
| 13 | + |
| 14 | +// RUN: %clang -print-target-triple \ |
| 15 | +// RUN: --target=arm64-apple-ios -mios-version-min=9 \ |
| 16 | +// RUN: -resource-dir=%S/Inputs/resource_dir 2>&1 \ |
| 17 | +// RUN: | FileCheck --check-prefix=CHECK-CLANGRT-IOS %s |
| 18 | +// CHECK-CLANGRT-IOS: arm64-apple-ios9.0.0 |
| 19 | + |
| 20 | +// RUN: %clang -print-target-triple \ |
| 21 | +// RUN: --target=arm64-apple-watchos -mwatchos-version-min=3 \ |
| 22 | +// RUN: -resource-dir=%S/Inputs/resource_dir 2>&1 \ |
| 23 | +// RUN: | FileCheck --check-prefix=CHECK-CLANGRT-WATCHOS %s |
| 24 | +// CHECK-CLANGRT-WATCHOS: arm64-apple-watchos3.0.0 |
| 25 | + |
| 26 | +// RUN: %clang -print-target-triple \ |
| 27 | +// RUN: --target=armv7k-apple-watchos -mwatchos-version-min=3 \ |
| 28 | +// RUN: -resource-dir=%S/Inputs/resource_dir 2>&1 \ |
| 29 | +// RUN: | FileCheck --check-prefix=CHECK-CLANGRT-WATCHOS-ARMV7K %s |
| 30 | +// CHECK-CLANGRT-WATCHOS-ARMV7K: thumbv7-apple-watchos3.0.0 |
| 31 | + |
| 32 | +// RUN: %clang -print-target-triple \ |
| 33 | +// RUN: --target=arm64-apple-tvos -mtvos-version-min=1\ |
| 34 | +// RUN: -resource-dir=%S/Inputs/resource_dir 2>&1 \ |
| 35 | +// RUN: | FileCheck --check-prefix=CHECK-CLANGRT-TVOS %s |
| 36 | +// CHECK-CLANGRT-TVOS: arm64-apple-tvos1.0.0 |
| 37 | + |
| 38 | +// RUN: %clang -print-target-triple \ |
| 39 | +// RUN: --target=arm64-apple-driverkit \ |
| 40 | +// RUN: -resource-dir=%S/Inputs/resource_dir 2>&1 \ |
| 41 | +// RUN: | FileCheck --check-prefix=CHECK-CLANGRT-DRIVERKIT %s |
| 42 | +// CHECK-CLANGRT-DRIVERKIT: arm64-apple-driverkit19.0.0 |
0 commit comments