According to the NVIDIA HPC SDK Installation Guide, although I export NVHPC_DEFAULT_CUDA=10.2 on terminal, the default cuda is still 22.7.
- export NVHPC_DEFAULT_CUDA=10.2 # define default cuda version
- ./install # install the nvhpc_2022_227_Linux_x86_64_cuda_multi
However, after the installer complete, I found that the symlinks in the directory /opt/nvidia/hpc_sdk/Linux_x86_64/22.7/cuda are as follows:
bin → 11.7/bin
include → 11.7/include
lib64 → 11.7/lib64
nvvm → 11.7/nvvm
In addition, I found that the output of /opt/nvidia/hpc_sdk/Linux_x86_64/compilers/bin/nvc -printcudaversion is 11.7.
Does NVHPC_DEFAULT_CUDA take any effect?
How to install HPC-SDK to support older CUDA-toolkit?
My environment is as follows:
OS: REHL 8.5
NVIDIA GPU Driver: 470.86 (nvidia-x11-drv-libs-470.86-2.el8_5.elrepo.x86_64, nvidia-x11-drv–470.86-2.el8_5.elrepo.x86_64, kmod-nvidia-470.86-2.el8_5.elrepo.x86_64)