Tell CMake where to find the compiler by setting either the environment variable "CUDACXX" or the CMake cache entry CMAKE_CUDA_COMPILER to the full path to the compiler, or to the compiler name if it is in the PATH.
时间: 2023-02-26 21:56:18 浏览: 139
This message is indicating that in order to compile a CUDA (Nvidia GPU programming) project using CMake (a cross-platform build system), you need to specify the location of the CUDA compiler. You can either set the environment variable "CUDACXX" or the CMake cache entry "CMAKE_CUDA_COMPILER" to the path of the compiler.
If the compiler is in your PATH, you can simply set the "CMAKE_CUDA_COMPILER" to the name of the compiler, otherwise you need to specify the full path to the compiler executable.
For example, if the CUDA compiler is located at "/usr/local/cuda/bin/nvcc", you can set the "CMAKE_CUDA_COMPILER" as follows:
```
set(CMAKE_CUDA_COMPILER "/usr/local/cuda/bin/nvcc")
```
Alternatively, you can set the "CUDACXX" environment variable:
```
export CUDACXX=/usr/local/cuda/bin/nvcc
```