RCurlインストールでエラー with Ubuntu
RCurlをインストールしようとするとエラーが発生した。
> install.packages('RCurl')
Installing package into ‘/usr/local/lib/R/site-library’
(as ‘lib’ is unspecified)
trying URL 'http://cran.rstudio.com/src/contrib/RCurl_1.95-4.1.tar.gz'
Content type 'application/x-gzip' length 870915 bytes (850 Kb)
opened URL
==================================================
downloaded 850 Kb
* installing *source* package ‘RCurl’ ...
** package ‘RCurl’ successfully unpacked and MD5 sums checked
checking for curl-config... no
Cannot find curl-config
ERROR: configuration failed for package ‘RCurl’
* removing ‘/usr/local/lib/R/site-library/RCurl’
Warning in install.packages :
installation of package ‘RCurl’ had non-zero exit status
The downloaded source packages are in
‘/tmp/Rtmpo09Ms9/downloaded_packages’
エラー内容からどうやらCurl関連のDevが必要そうだ。
(対策)
$ sudo apt-get install libcurl4-openssl-dev
これだ!
> install.packages('RCurl')
Installing package into ‘/usr/local/lib/R/site-library’
..............
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded
* DONE (RCurl)