Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[vcpkg_download_distfile] Fix the parameter mismatch issues of some internal functions and fix the recursive call (step 3) #20585

Merged
merged 12 commits into from
Nov 26, 2021
6 changes: 5 additions & 1 deletion scripts/cmake/vcpkg_download_distfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ function(z_vcpkg_download_distfile_test_hash path kind error_advice sha512 skip_
" File path: [ ${file_path} ]\n"
" Expected hash: [ ${sha512} ]\n"
" Actual hash: [ ${file_hash} ]\n"
"${CUSTOM_ERROR_ADVICE}\n")
"${error_advice}\n")
endif()
endfunction()

Expand Down Expand Up @@ -140,6 +140,8 @@ function(z_vcpkg_download_distfile_via_aria filename urls headers sha512 skip_sh
"${DOWNLOADS}/temp/${filename}"
"downloaded file"
"The file may have been corrupted in transit."
"${sha512}"
${skip_sha512}
)
file(REMOVE
${DOWNLOADS}/download-${filename}-out.log
Expand Down Expand Up @@ -218,6 +220,8 @@ If you do not know the SHA512, add it as 'SHA512 0' and re-run this command.")
"${downloaded_file_path}"
"cached file"
"Please delete the file and retry if this file should be downloaded again."
"${arg_SHA512}"
${arg_SKIP_SHA512}
)
set("${out_var}" "${downloaded_file_path}" PARENT_SCOPE)
return()
Expand Down