2016-04-20 02:52:28 +08:00
|
|
|
// REQUIRES: clang-driver
|
|
|
|
|
|
|
|
// Check that we raise an error if we're trying to compile CUDA code but can't
|
|
|
|
// find a CUDA install, unless -nocudainc was passed.
|
|
|
|
|
2018-01-31 16:26:51 +08:00
|
|
|
// RUN: %clang -### --sysroot=%s/no-cuda-there --cuda-path-ignore-env %s 2>&1 | FileCheck %s --check-prefix ERR
|
2016-04-20 02:52:28 +08:00
|
|
|
// RUN: %clang -### --cuda-path=%s/no-cuda-there %s 2>&1 | FileCheck %s --check-prefix ERR
|
|
|
|
// ERR: cannot find CUDA installation
|
|
|
|
|
2018-01-31 16:26:51 +08:00
|
|
|
// RUN: %clang -### -nocudainc --sysroot=%s/no-cuda-there --cuda-path-ignore-env %s 2>&1 | FileCheck %s --check-prefix OK
|
2016-04-20 02:52:28 +08:00
|
|
|
// RUN: %clang -### -nocudainc --cuda-path=%s/no-cuda-there %s 2>&1 | FileCheck %s --check-prefix OK
|
|
|
|
// OK-NOT: cannot find CUDA installation
|