5555
5656 # The binary archives (redist) are guaranteed to be updated as part of the release posting.
5757 CTK_BASE_URL="https://developer.download.nvidia.com/compute/cuda/redist/"
58- CTK_JSON_URL="$CTK_BASE_URL/redistrib_${{ inputs.cuda-version }}.json"
5958 if [[ "${{ inputs.host-platform }}" == linux* ]]; then
6059 if [[ "${{ inputs.host-platform }}" == "linux-64" ]]; then
6160 CTK_SUBDIR="linux-x86_64"
@@ -74,13 +73,15 @@ runs:
7473 rm -rf $_TEMP_DIR_
7574 }
7675 fi
76+
7777 function populate_cuda_path() {
7878 # take the component name as a argument
7979 function download() {
8080 curl -kLSs $1 -o $2
8181 }
82- CTK_COMPONENT=$1
83- CTK_COMPONENT_REL_PATH="$(curl -s $CTK_JSON_URL |
82+ local CTK_COMPONENT=$1
83+ local CTK_VERSION=$2
84+ CTK_COMPONENT_REL_PATH="$(curl -s ${CTK_BASE_URL}/redistrib_${CTK_VERSION}.json |
8485 python -c "import sys, json; print(json.load(sys.stdin)['${CTK_COMPONENT}']['${CTK_SUBDIR}']['relative_path'])")"
8586 CTK_COMPONENT_URL="${CTK_BASE_URL}/${CTK_COMPONENT_REL_PATH}"
8687 CTK_COMPONENT_COMPONENT_FILENAME="$(basename $CTK_COMPONENT_REL_PATH)"
9798 CTK_CACHE_COMPONENTS="${CTK_CACHE_COMPONENTS//,,/,}"
9899 # Get headers and shared libraries in place
99100 for item in $(echo $CTK_CACHE_COMPONENTS | tr ',' ' '); do
100- populate_cuda_path "$item"
101+ ctk_version="${{ inputs.cuda-version }}"
102+ if [[ "$item" == "cuda_sanitizer_api" ]]; then
103+ # Always use latest CTK for cuda_sanitizer_api
104+ # FIXME: Automatically track latest CTK version
105+ ctk_version="12.8.1"
106+ fi
107+ populate_cuda_path "$item" "$ctk_version"
101108 done
102109 ls -l $CUDA_PATH
103110
0 commit comments