问题
Initially I was trying to use devtools::install_github("EdwinTh/padr")
where I got the following error:
Error in curl::new_handle() : An unknown option was passed in to libcurl
After some time I found out that devtools
uses curl/RCurl
which wraps the current version of curl
on the host machine.
The host(Ubuntu 14.04.5 LTS) machine version of curl
is:
1$ curl -V
curl 7.61.0 (x86_64-pc-linux-gnu) libcurl/7.61.0 OpenSSL/1.0.1f zlib/1.2.8 libssh2/1.8.0 librtmp/2.3
where curl
is located in:
12$ which curl
/usr/local/bin/curl
and is working fine when using curl::new_handle()
directly from the terminal
In comparison the curl/RCurl
version is:
> RCurl::curlVersion()
$age
[1] 3
$version
[1] "7.35.0"`
I'm assuming that this might be the underlying issue. My problem now is how to let Rs curl/RCurl
point to the corresponding version.
I have tried everything I found so far on that topic for R
like:
install.packages("RCurl", type="source")
and
install.packages("curl", type="source")
as well as adjusting curl
on the host machine:
wget https://libssh2.org/download/libssh2-1.8.0.tar.gz
tar zxvf llibssh2-1.8.0.tar.gz
cd libssh2-1.8.0
./configure
make
sudo make install
wget http://curl.haxx.se/download/curl-7.61.0.tar.gz
tar zxvf curl-7.61.0.tar.bz2
cd curl-7.61.0
./configure --with-libssh2=/usr/local
make
sudo make install
But I always get the same version for curl/RCurl
7.35.0 instead of 7.61.0.
Appreciate any insights!
来源:https://stackoverflow.com/questions/51571901/how-to-update-rcurl-and-curl-to-the-version-on-the-host-machine