While working on my master’s final project, I needed to build Adios2. Adios2 is a framework for scientific data I/O that is based on MPI-IO. From its documentation, I found several optional features, such as CUDA support and UCX, that can be utilised. These features can be turned on by specifying a particular flag. I tried to build Adios2 with CUDA support on the Cirrus login node.
Since Adios2 can be built using CMake, we need to give `-DADIOS2_USE_CUDA=ON`. However, an error stopped the CMake configuration, saying: Could NOT find CUDAToolkit (missing: CUDAToolkit_INCLUDE_DIR CUDA_CUDART)
I tried to Google-fu the error message with no success. Then, the following “right thing” to do is to read the CMake documentation, particularly about find_package. Following the page, I add a CMake configuration variable, `CUDAToolkit_ROOT`, pointing to the CUDA directory. And the issue was solved~