Unable To Install Tidyverse Due To Libcurl Issue - r

I recently upgraded to R 3.5 and have been unable to install the 'tidyverse' package. Other packages are installing fine. Whenever I try to install tidyverse, I receive the following error message.
* installing *source* package ‘curl’ ...
** package ‘curl’ successfully unpacked and MD5 sums checked
Found pkg-config cflags and libs!
Using PKG_CFLAGS=-I/usr/include/x86_64-linux-gnu
Using PKG_LIBS=-lcurl
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because libcurl was not found. Try installing:
* deb: libcurl4-openssl-dev (Debian, Ubuntu, etc)
* rpm: libcurl-devel (Fedora, CentOS, RHEL)
* csw: libcurl_dev (Solaris)
If libcurl is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a libcurl.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘curl’
* removing ‘/home/nik/anaconda3/lib/R/library/curl’
ERROR: dependency ‘curl’ is not available for package ‘httr’
* removing ‘/home/nik/anaconda3/lib/R/library/httr’
ERROR: dependency ‘httr’ is not available for package ‘rvest’
* removing ‘/home/nik/anaconda3/lib/R/library/rvest’
ERROR: dependencies ‘httr’, ‘rvest’ are not available for package ‘tidyverse’
* removing ‘/home/nik/anaconda3/lib/R/library/tidyverse’
The downloaded source packages are in
‘/tmp/RtmpHJ48Sk/downloaded_packages’
Updating HTML index of packages in '.Library'
Making 'packages.html' ... done
Warning messages:
1: In install.packages("tidyverse") :
installation of package ‘curl’ had non-zero exit status
2: In install.packages("tidyverse") :
installation of package ‘httr’ had non-zero exit status
3: In install.packages("tidyverse") :
installation of package ‘rvest’ had non-zero exit status
4: In install.packages("tidyverse") :
installation of package ‘tidyverse’ had non-zero exit status
I have run sudo apt-get install libcurl4-openssl-dev as has been suggested on other threads for the same problem. However, this does not appear to resolve the issue (in fact, libcurl was already installed, and reinstalling it also did not work).
When I check $PATH, I do not see 'pkg-config', and PKG_CONFIG_PATH does not seem to exist. Adding /usr/bin/pkg-config to the path and setting PKG_CONFIG_PATH /home/nik/anaconda3/lib/pkgconfig/libcurl.pc also does not appear to have fixed the issue. I'm at wits end at this point, as I can't think of anything else to uninstall/reinstall, nor figure out why libcurl isn't being added to the path on its own when I install it. Any help at all would be appreciated.

try setting your path to the directory that contains libcurl and not to libcurl itself, i.e.
PKG_CONFIG_PATH=/home/nik/anaconda3/lib/pkgconfig

Related

"minfi" package install not successful for R 3.6 on Ubuntu 20.04

I am using R 3.6 on Linux (this is the most recent R version for Linux) and I need to perform methylation analysis on Infinium HumanMethylation450k data and for that I need the "minfi" R package.
For that I used this code:
install.packages("BiocManager")
BiocManager::install('minfi')
install.packages("minfi")
I also tried this:
if (!requireNamespace("BiocManager", quietly = TRUE))
install.packages("BiocManager")
BiocManager::install("minfi")
then:
library(minfi)
This is what I get:
Error in library(minfi) : there is no package called ‘minfi’
I also get many warnings and errors after installing the package:
ERROR: compilation failed for package ‘Rhtslib’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/Rhtslib’
* installing *source* package ‘openssl’ ...
** package ‘openssl’ successfully unpacked and MD5 sums checked
** using staged installation
Using PKG_CFLAGS=
--------------------------- [ANTICONF] --------------------------------
Configuration failed because openssl was not found. Try installing:
* deb: libssl-dev (Debian, Ubuntu, etc)
* rpm: openssl-devel (Fedora, CentOS, RHEL)
* csw: libssl_dev (Solaris)
* brew: openssl#1.1 (Mac OSX)
If openssl is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a openssl.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
ERROR: configuration failed for package ‘XML’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/XML’
* installing *source* package ‘curl’ ...
** package ‘curl’ successfully unpacked and MD5 sums checked
** using staged installation
Package libcurl was not found in the pkg-config search path.
Perhaps you should add the directory containing `libcurl.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libcurl' found
Package libcurl was not found in the pkg-config search path.
Perhaps you should add the directory containing `libcurl.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libcurl' found
Using PKG_CFLAGS=
Using PKG_LIBS=-lcurl
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because libcurl was not found. Try installing:
* deb: libcurl4-openssl-dev (Debian, Ubuntu, etc)
* rpm: libcurl-devel (Fedora, CentOS, RHEL)
* csw: libcurl_dev (Solaris)
If libcurl is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a libcurl.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘curl’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/curl’
* installing *source* package ‘RCurl’ ...
** package ‘RCurl’ successfully unpacked and MD5 sums checked
** using staged installation
checking for curl-config... no
Cannot find curl-config
ERROR: configuration failed for package ‘RCurl’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/RCurl’
* installing *source* package ‘xml2’ ...
** package ‘xml2’ successfully unpacked and MD5 sums checked
** using staged installation
Package libxml-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `libxml-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libxml-2.0' found
Package libxml-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `libxml-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libxml-2.0' found
Using PKG_CFLAGS=
Using PKG_LIBS=-lxml2
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because libxml-2.0 was not found. Try installing:
* deb: libxml2-dev (Debian, Ubuntu, etc)
* rpm: libxml2-devel (Fedora, CentOS, RHEL)
* csw: libxml2_dev (Solaris)
If libxml-2.0 is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a libxml-2.0.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘xml2’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/xml2’
ERROR: dependency ‘openssl’ is not available for package ‘base64’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/base64’
ERROR: dependencies ‘XML’, ‘RCurl’ are not available for package ‘annotate’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/annotate’
ERROR: dependencies ‘curl’, ‘openssl’ are not available for package ‘httr’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/httr’
ERROR: dependency ‘RCurl’ is not available for package ‘GenomeInfoDb’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/GenomeInfoDb’
ERROR: dependencies ‘curl’, ‘httr’ are not available for package ‘BiocFileCache’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/BiocFileCache’
ERROR: dependency ‘GenomeInfoDb’ is not available for package ‘GenomicRanges’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/GenomicRanges’
ERROR: dependency ‘base64’ is not available for package ‘illuminaio’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/illuminaio’
ERROR: dependency ‘annotate’ is not available for package ‘genefilter’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/genefilter’
ERROR: dependencies ‘httr’, ‘xml2’ are not available for package ‘GEOquery’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/GEOquery’
ERROR: dependencies ‘GenomeInfoDb’, ‘GenomicRanges’, ‘Rhtslib’ are not available for package ‘Rsamtools’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/Rsamtools’
ERROR: dependencies ‘XML’, ‘httr’, ‘openssl’, ‘BiocFileCache’ are not available for package ‘biomaRt’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/biomaRt’
ERROR: dependencies ‘GenomicRanges’, ‘GenomeInfoDb’ are not available for package ‘SummarizedExperiment’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/SummarizedExperiment’
ERROR: dependencies ‘GenomeInfoDb’, ‘GenomicRanges’, ‘SummarizedExperiment’, ‘Rsamtools’ are not available for package ‘GenomicAlignments’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/GenomicAlignments’
ERROR: dependencies ‘GenomicRanges’, ‘XML’, ‘GenomeInfoDb’, ‘RCurl’, ‘Rsamtools’, ‘GenomicAlignments’ are not available for package ‘rtracklayer’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/rtracklayer’
ERROR: dependencies ‘GenomeInfoDb’, ‘GenomicRanges’, ‘RCurl’, ‘rtracklayer’, ‘biomaRt’ are not available for package ‘GenomicFeatures’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/GenomicFeatures’
ERROR: dependencies ‘GenomeInfoDb’, ‘GenomicRanges’, ‘GenomicFeatures’ are not available for package ‘bumphunter’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/bumphunter’
ERROR: dependencies ‘GenomicRanges’, ‘SummarizedExperiment’, ‘bumphunter’, ‘GenomeInfoDb’, ‘illuminaio’, ‘genefilter’, ‘GEOquery’ are not available for package ‘minfi’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/minfi’
The downloaded source packages are in
‘/tmp/RtmpDInss9/downloaded_packages’
Installation path not writeable, unable to update packages: boot, class, KernSmooth,
lattice, MASS, mgcv, nlme, nnet, spatial, survival
There were 23 warnings (use warnings() to see them)
> install.packages("minfi")
Installing package into ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6’
(as ‘lib’ is unspecified)
Warning in install.packages :
package ‘minfi’ is not available (for R version 3.6.3)
> install.packages("BiocManager")
Error in install.packages : Updating loaded packages
> install.packages("BiocManager")
Installing package into ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6’
(as ‘lib’ is unspecified)
trying URL 'https://cran.uni-muenster.de/src/contrib/BiocManager_1.30.10.tar.gz'
Content type 'application/x-gzip' length 40205 bytes (39 KB)
==================================================
I also tried this to check if "minfi" is available for my current R version:
remove.packages("BiocVersion")
avail <- BiocManager::available()
length(avail) # all CRAN & Bioconductor packages
BiocManager::available("minfi")
and this is what i get:
> avail <- BiocManager::available()
> length(avail) # all CRAN & Bioconductor packages
[1] 19463
> BiocManager::available("minfi")
[1] "minfi" "minfiData" "minfiDataEPIC"
I also installed libcurl4-openssl-dev and libxml2-dev as #Alexlok recommended, they obviously were needed but now I get different errors:
installing to /home/melshark/R/x86_64-pc-linux-gnu-library/3.6/00LOCK-
rtracklayer/00new/rtracklayer/libs
** R
** data
** demo
** inst
** byte-compile and prepare package for lazy loading
Creating a generic function for ‘offset’ from package ‘stats’ in package ‘rtracklayer’
Creating a generic function from function ‘uri’ in package ‘rtracklayer’
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** checking absolute paths in shared objects and dynamic libraries
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (rtracklayer)
ERROR: dependency ‘biomaRt’ is not available for package ‘GenomicFeatures’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/GenomicFeatures’
ERROR: dependency ‘GenomicFeatures’ is not available for package ‘bumphunter’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/bumphunter’
ERROR: dependencies ‘bumphunter’, ‘illuminaio’, ‘GEOquery’ are not available for package ‘minfi’
* removing ‘/home/melshark/R/x86_64-pc-linux-gnu-library/3.6/minfi’
The downloaded source packages are in
‘/tmp/RtmpWmvmxL/downloaded_packages’
Installation path not writeable, unable to update packages: spatial, survival
Warning messages:
1: In install.packages(...) :
installation of package ‘openssl’ had non-zero exit status
2: In install.packages(...) :
installation of package ‘base64’ had non-zero exit status
3: In install.packages(...) :
installation of package ‘httr’ had non-zero exit status
4: In install.packages(...) :
installation of package ‘BiocFileCache’ had non-zero exit status
5: In install.packages(...) :
installation of package ‘illuminaio’ had non-zero exit status
6: In install.packages(...) :
installation of package ‘GEOquery’ had non-zero exit status
7: In install.packages(...) :
installation of package ‘biomaRt’ had non-zero exit status
8: In install.packages(...) :
installation of package ‘GenomicFeatures’ had non-zero exit status
9: In install.packages(...) :
installation of package ‘bumphunter’ had non-zero exit status
10: In install.packages(...) :
installation of package ‘minfi’ had non-zero exit status
How can I solve this problem?

curl package not available for several R packages

I just installed ubunutu 18.04 and I successfully install R version 3.5.1. I am having problems installing R packages such as plotly. It seems that the packages curl and httr are not available. The full error message:
> install.packages("plotly")
Installing package into ‘/home/lualeperez/R/x86_64-pc-linux-gnu-library/3.5’
(as ‘lib’ is unspecified)
also installing the dependencies ‘curl’, ‘openssl’, ‘httr’
trying URL 'https://cloud.r-project.org/src/contrib/curl_3.2.tar.gz'
Content type 'application/x-gzip' length 367047 bytes (358 KB)
==================================================
downloaded 358 KB
trying URL 'https://cloud.r-project.org/src/contrib/openssl_1.0.2.tar.gz'
Content type 'application/x-gzip' length 1194883 bytes (1.1 MB)
==================================================
downloaded 1.1 MB
trying URL 'https://cloud.r-project.org/src/contrib/httr_1.3.1.tar.gz'
Content type 'application/x-gzip' length 147593 bytes (144 KB)
==================================================
downloaded 144 KB
trying URL 'https://cloud.r-project.org/src/contrib/plotly_4.8.0.tar.gz'
Content type 'application/x-gzip' length 1860673 bytes (1.8 MB)
==================================================
downloaded 1.8 MB
* installing *source* package ‘curl’ ...
** package ‘curl’ successfully unpacked and MD5 sums checked
Package libcurl was not found in the pkg-config search path.
Perhaps you should add the directory containing `libcurl.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libcurl' found
Package libcurl was not found in the pkg-config search path.
Perhaps you should add the directory containing `libcurl.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libcurl' found
Using PKG_CFLAGS=
Using PKG_LIBS=-lcurl
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because libcurl was not found. Try installing:
* deb: libcurl4-openssl-dev (Debian, Ubuntu, etc)
* rpm: libcurl-devel (Fedora, CentOS, RHEL)
* csw: libcurl_dev (Solaris)
If libcurl is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a libcurl.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘curl’
* removing ‘/home/lualeperez/R/x86_64-pc-linux-gnu-library/3.5/curl’
* installing *source* package ‘openssl’ ...
** package ‘openssl’ successfully unpacked and MD5 sums checked
Using PKG_CFLAGS=
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because openssl was not found. Try installing:
* deb: libssl-dev (Debian, Ubuntu, etc)
* rpm: openssl-devel (Fedora, CentOS, RHEL)
* csw: libssl_dev (Solaris)
* brew: openssl#1.1 (Mac OSX)
If openssl is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a openssl.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘openssl’
* removing ‘/home/lualeperez/R/x86_64-pc-linux-gnu-library/3.5/openssl’
ERROR: dependencies ‘curl’, ‘openssl’ are not available for package ‘httr’
* removing ‘/home/lualeperez/R/x86_64-pc-linux-gnu-library/3.5/httr’
ERROR: dependency ‘httr’ is not available for package ‘plotly’
* removing ‘/home/lualeperez/R/x86_64-pc-linux-gnu-library/3.5/plotly’
The downloaded source packages are in
‘/tmp/RtmpNTZBPJ/downloaded_packages’
Warning messages:
1: In install.packages("plotly") :
installation of package ‘curl’ had non-zero exit status
2: In install.packages("plotly") :
installation of package ‘openssl’ had non-zero exit status
3: In install.packages("plotly") :
installation of package ‘httr’ had non-zero exit status
4: In install.packages("plotly") :
installation of package ‘plotly’ had non-zero exit status
I tried to solve the problem by installing libcurl4 by doing
sudo apt-get install libcurl4
but the systems then removes all the r-base dependencies.
I haven't tried to solve the problem with the httr package.
Does any one have any hint on how to solve this problem?
Just ran into the same issue, this is the solution I found:
Since just installing libcurl4-openssl-dev removes all the r-base packages what I did was
sudo apt-get install libcurl4-openssl-dev r-base
and afterwards
R -q -e "install.packages(c('curl'))"
and it worked.
Only caveat is that it upgrades your R version, but if you are already using the latest one then its not an issue.
You are attempting to compile from source. That sometimes has so-called build dependencies. You are missing them, and you are overlooking the (somewhat clear) error messages to that extend because you are getting swamped by multiple installations.
So first tip, so it one package at a time.
Second tip: realize that many (if not all) of these are available within Ubuntu. So just do
sudo apt install r-cran-curl
to install e.g. curl. Ditto for the others.
Third tip: There are over 3000 CRAN packages for Ubuntu at Michael's PPA. Read the top of
this README and then go this PPA (provided you want 3.5 which you do).
Fedora 36:
dnf install cmake
dnf install openssl-devel
dnf install libcurl-devel.x86_64

Installation of quantmod in R

I try to install R quantmod
When I try:
install.packages('quantmod')
I see:
Installing package into ‘/usr/local/lib/R/site-library’
(as ‘lib’ is unspecified)
also installing the dependency ‘curl’
trying URL 'https://cloud.r-project.org/src/contrib/curl_3.1.tar.gz'
Content type 'application/x-gzip' length 366086 bytes (357 KB)
==================================================
downloaded 357 KB
trying URL 'https://cloud.r-project.org/src/contrib/quantmod_0.4-
12.tar.gz'
Content type 'application/x-gzip' length 140216 bytes (136 KB)
==================================================
downloaded 136 KB
* installing *source* package ‘curl’ ...
** package ‘curl’ successfully unpacked and MD5 sums checked
Package libcurl was not found in the pkg-config search path.
Perhaps you should add the directory containing `libcurl.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libcurl' found
Package libcurl was not found in the pkg-config search path.
Perhaps you should add the directory containing `libcurl.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libcurl' found
Using PKG_CFLAGS=
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because libcurl was not found. Try installing:
* deb: libcurl4-openssl-dev (Debian, Ubuntu, etc)
* rpm: libcurl-devel (Fedora, CentOS, RHEL)
* csw: libcurl_dev (Solaris)
If libcurl is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a libcurl.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘curl’
* removing ‘/usr/local/lib/R/site-library/curl’
Warning in install.packages :
installation of package ‘curl’ had non-zero exit status
ERROR: dependency ‘curl’ is not available for package ‘quantmod’
* removing ‘/usr/local/lib/R/site-library/quantmod’
Warning in install.packages :
installation of package ‘quantmod’ had non-zero exit status
The downloaded source packages are in
‘/tmp/RtmpeR1Cmy/downloaded_packages’ Using PKG_LIBS=-lcurl
And I can't run this library.
When I try:
install.packages("quantmod", repos="https://github.com/joshuaulrich/quantmod")
I see:
Warning in install.packages :
package ‘quantmod’ is not available (for R version 3.4.4)
But R version 3.4.4 is the latest!!
What is the problem?
P.S. My R version 3.4.4 (2018-03-15) -- "Someone to Lean On"
Linux Mint 17.2 Rafaela
It looks like you need to install curl for your system. Open a terminal and run:
sudo apt-get update
sudo apt-get install curl libcurl4-openssl-dev libssl-dev
Then try again in R to install your package:
install.packages('quantmod')
If this doesn't work edit your question and post any additional error messages.

Cannot Install RMySQL on CENTOS

I am finding it very difficult to install the "RMySQL" package on CENTOS.
install.packages("RMySQL", dependencies = TRUE, repos = "http://cran.rstudio.com/")
The error it is throwing me is:
* installing *source* package ‘RMySQL’ ...
** package ‘RMySQL’ successfully unpacked and MD5 sums checked
Using PKG_CFLAGS=
Using PKG_LIBS=-lmysqlclient
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because libmysqlclient was not found. Try installing:
* deb: libmariadb-client-lgpl-dev (Debian, Ubuntu 16.04)
libmariadbclient-dev (Ubuntu 14.04)
* rpm: mariadb-devel | mysql-devel (Fedora, CentOS, RHEL)
* csw: mysql56_dev (Solaris)
* brew: mariadb-connector-c (OSX)
If libmysqlclient is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a libmysqlclient.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘RMySQL’
* removing ‘/usr/local/lib64/R/library/RMySQL’
The downloaded source packages are in
‘/tmp/RtmpbFMPmO/downloaded_packages’
Updating HTML index of packages in '.Library'
Making 'packages.html' ... done
Warning message:
In install.packages("RMySQL", dependencies = TRUE, repos = "http://cran.rstudio.com/") :
installation of package ‘RMySQL’ had non-zero exit status
I have already installed yum update mysql-devel but still get the same error.
Any help will be appreciated as I have been trying to figure his out since last 2 days.

Error when installing swirl in RStudio 3.1.2

Hey I tried installing swirl running the following command:
install.packages("swirl")
I got the following error:
------------------------- ANTICONF ERROR ------------------------- --
Configuration failed because libcurl was not found. Try installing:
* deb: libcurl4-openssl-dev (Debian, Ubuntu, etc)
* rpm: libcurl-devel (Fedora, CentOS, RHEL)
* csw: libcurl_dev (Solaris)
If libcurl is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a libcurl.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘curl’
* removing ‘/home/franco/R/x86_64-pc-linux-gnu-library/3.1/curl’
Warning in install.packages :
installation of package ‘curl’ had non-zero exit status
* 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 ‘/home/franco/R/x86_64-pc-linux-gnu-library/3.1/RCurl’
Warning in install.packages :
installation of package ‘RCurl’ had non-zero exit status
ERROR: dependency ‘curl’ is not available for package ‘httr’
* removing ‘/home/franco/R/x86_64-pc-linux-gnu-library/3.1/httr’
Warning in install.packages :
installation of package ‘httr’ had non-zero exit status
ERROR: dependencies ‘httr’, ‘RCurl’ are not available for package ‘swirl’
* removing ‘/home/franco/R/x86_64-pc-linux-gnu-library/3.1/swirl’
Warning in install.packages :
installation of package ‘swirl’ had non-zero exit status
The downloaded source packages are in
‘/tmp/Rtmp7G87EM/downloaded_packages’
I tried installing "curl" and "RCurl" packages but I got the same error messages. I don't know how to change the path as directed in the ANTICONF ERROR.
I'm running Ubuntu 15.04 and R version 3.1.2 (2014-10-31)
now it's
sudo apt-get install libcurl4-gnutls-dev
Updated as on 30-05-2019:
I am using Ubuntu 16.04
I got this while installing the packages-
Using PKG_CFLAGS=
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because openssl was not found. Try installing: *
deb: libssl-dev (Debian, Ubuntu, etc) * rpm: openssl-devel (Fedora,
CentOS, RHEL) * csw: libssl_dev (Solaris) * brew: openssl#1.1 (Mac
OSX) If openssl is already installed, check that 'pkg-config' is in
your PATH and PKG_CONFIG_PATH contains a openssl.pc file. If
pkg-config is unavailable you can set INCLUDE_DIR and LIB_DIR manually
via: R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
I used the command in terminal >
sudo apt-get install libssl-dev
And then it worked fine.

Resources