Justin Lebar | b34d7bc | 2016-04-19 18:52:28 +0000 | [diff] [blame] | 1 | // REQUIRES: clang-driver |
| 2 | |
| 3 | // Check that we raise an error if we're trying to compile CUDA code but can't |
| 4 | // find a CUDA install, unless -nocudainc was passed. |
| 5 | |
Jonas Hahnfeld | 7f9c518 | 2018-01-31 08:26:51 +0000 | [diff] [blame] | 6 | // RUN: %clang -### --sysroot=%s/no-cuda-there --cuda-path-ignore-env %s 2>&1 | FileCheck %s --check-prefix ERR |
Justin Lebar | b34d7bc | 2016-04-19 18:52:28 +0000 | [diff] [blame] | 7 | // RUN: %clang -### --cuda-path=%s/no-cuda-there %s 2>&1 | FileCheck %s --check-prefix ERR |
| 8 | // ERR: cannot find CUDA installation |
| 9 | |
Jonas Hahnfeld | 7f9c518 | 2018-01-31 08:26:51 +0000 | [diff] [blame] | 10 | // RUN: %clang -### -nocudainc --sysroot=%s/no-cuda-there --cuda-path-ignore-env %s 2>&1 | FileCheck %s --check-prefix OK |
Justin Lebar | b34d7bc | 2016-04-19 18:52:28 +0000 | [diff] [blame] | 11 | // RUN: %clang -### -nocudainc --cuda-path=%s/no-cuda-there %s 2>&1 | FileCheck %s --check-prefix OK |
| 12 | // OK-NOT: cannot find CUDA installation |