Monday, February 27, 2023

Re: [proposal] set curl as default download method

On 2/27/23 18:49, Stuart Henderson wrote:

> Ah, looking at that file note the difference between "curl" and
> "libcurl", it seems that it tries to use libcurl first and then there
> are fallbacks to use wget/curl binaries. So it seems the lines you
> patched wouldn't have been reached in the first place if libcurl
> detection was working properly?

It's a fallback yes, but the fallback is implemented in function
posixMethod(), which takes the fallback as a parameter, but only uses it
if haveLibcurl==false:

posixMethod <- function(utility) {
if (haveLibcurl)
"libcurl"
else if (nzchar(Sys.which(utility)))
utility
else
""
}

I'm quite certain that libcurl detection works and that
haveLibcurl==true on OpenBSD, but unless the OS is one of "Windows",
"Darwin" or "Linux", posixMethod() is never called, libcurl is never
detected, and an empty string is returned...

No comments:

Post a Comment