Confused when installing tidyverse on RStudio (R 3.6.0, RStudio 1.2.1335, Linux debian 9.8)

Hey, RStudio community!

So I've finally gotten RStudio downloaded and working on my Pixelbook using the Linux beta (3.6.0 and newest version of RStudio).

I opened up Rstudio and then tried to install tidyverse- the process was taking almost twenty minutes so I tried to quit Rstudio which then took another few minutes to shut down.

I then opened the app up to try again but now it shows that the tidyverse packages are present on the side. I tried to use library(tidyverse) but it says that there is no package with that name. I was able to use library(ggplot2) and library(tibble).

Did these packages install correctly without tidyverse actually installing? I've used RStudio before but only on windows systems and my Linux experience thus far has been difficult. When I had installed packages like tidyverse in the past on Windows systems it never took longer than a few minutes and always actually ended in console output. I appreciate any clarity you can offer me!
EDIT: I quit the installing of readr because I saw it in the package list. Then the console restored the previous thing right before I did library(tidyverse).

UPDATE: So I tried to install sparklyr and am stuck in a similar endless stream of console output... I can't link the output because it is constantly adding and scrolling and I can no longer scroll to the top of the output. Is anyone familiar with this?

Here is all of the console output from this session:

 install.packages("ggplot2")
Installing package into ‘/home/ishan16d/R/x86_64-pc-linux-gnu-library/3.6’
(as ‘lib’ is unspecified)
trying URL 'https://cloud.r-project.org/src/contrib/ggplot2_3.2.0.tar.gz'
Content type 'application/x-gzip' length 3193995 bytes (3.0 MB)
==================================================
downloaded 3.0 MB

* installing *source* package ‘ggplot2’ ...
** package ‘ggplot2’ successfully unpacked and MD5 sums checked
** using staged installation
** R
** data
*** moving datasets to lazyload DB
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
*** copying figures
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (ggplot2)

The downloaded source packages are in
	‘/tmp/RtmpzpUVJ5/downloaded_packages’
> install.packages("readr")
Installing package into ‘/home/ishan16d/R/x86_64-pc-linux-gnu-library/3.6’
(as ‘lib’ is unspecified)
trying URL 'https://cloud.r-project.org/src/contrib/readr_1.3.1.tar.gz'
Content type 'application/x-gzip' length 268853 bytes (262 KB)
==================================================
downloaded 262 KB

* installing *source* package ‘readr’ ...
** package ‘readr’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG  -I"/home/ishan16d/R/x86_64-pc-linux-gnu-library/3.6/Rcpp/include" -I"/home/ishan16d/R/x86_64-pc-linux-gnu-library/3.6/BH/include"  -I. -Ircon -fpic  -g -O2 -fdebug-prefix-map=/home/jranke/git/r-backports/stretch/r-base-3.6.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g  -c Collector.cpp -o Collector.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG  -I"/home/ishan16d/R/x86_64-pc-linux-gnu-library/3.6/Rcpp/include" -I"/home/ishan16d/R/x86_64-pc-linux-gnu-library/3.6/BH/include"  -I. -Ircon -fpic  -g -O2 -fdebug-prefix-map=/home/jranke/git/r-backports/stretch/r-base-3.6.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g  -c CollectorGuess.cpp -o CollectorGuess.o
/usr/lib/R/etc/Makeconf:176: recipe for target 'CollectorGuess.o' failed
make: *** [CollectorGuess.o] Interrupt
ERROR: compilation failed for package ‘readr’
* removing ‘/home/ishan16d/R/x86_64-pc-linux-gnu-library/3.6/readr’
* restoring previous ‘/home/ishan16d/R/x86_64-pc-linux-gnu-library/3.6/readr’

> library(tidyverse)
Error in library(tidyverse) : there is no package called ‘tidyverse’
> library(ggplot2)

If you're getting this, it means tidyverse did not install.

Yes, it is normal installation process, maybe is just taking longer than you are used to.

I'll try to let it run as long as I can now. I lost patience after twenty minutes but I'll see.

Yeah I know I quit the installation process but the weird part is that individual tidyverse packages like ggplot2, diplyr, and purr all showed up after I force quit the program. ggplot2 is the only one that I installed separately and the rest definitely weren't there the first time I booted rsrudio up.

Those are the ones that got installed before you force quit, each package gets installed independently not as a whole.

Ok so basically it installed all the packages except 3 of them: httr, rvest, xml2.

All the others, from this list: https://tidyverse.tidyverse.org/reference/tidyverse_packages.html, installed.

Should I just remove all packages and then try to reinstall tidyverse and give it as much time as possible? Or should I try to install those remaining packages separately.

If I were to remove all packages and start from scratch how would I do that?

So I tried to install httr using install.packages("httr") and this is the output that I got:

The package does not appear in the list

Installing package into ‘/home/ishan16d/R/x86_64-pc-linux-gnu-library/3.6’
(as ‘lib’ is unspecified)
also installing the dependencies ‘curl’, ‘openssl’

trying URL 'https://cloud.r-project.org/src/contrib/curl_3.3.tar.gz'
Content type 'application/x-gzip' length 371740 bytes (363 KB)
==================================================
downloaded 363 KB

trying URL 'https://cloud.r-project.org/src/contrib/openssl_1.4.tar.gz'
Content type 'application/x-gzip' length 1202838 bytes (1.1 MB)
==================================================
downloaded 1.1 MB

trying URL 'https://cloud.r-project.org/src/contrib/httr_1.4.0.tar.gz'
Content type 'application/x-gzip' length 156356 bytes (152 KB)
==================================================
downloaded 152 KB

* 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/ishan16d/R/x86_64-pc-linux-gnu-library/3.6/curl’
Warning in install.packages :
  installation of package ‘curl’ had non-zero exit status
* installing *source* package ‘openssl’ ...
** package ‘openssl’ successfully unpacked and MD5 sums checked
** using staged installation
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/ishan16d/R/x86_64-pc-linux-gnu-library/3.6/openssl’
Warning in install.packages :
  installation of package ‘openssl’ had non-zero exit status
ERROR: dependencies ‘curl’, ‘openssl’ are not available for package ‘httr’
* removing ‘/home/ishan16d/R/x86_64-pc-linux-gnu-library/3.6/httr’
Warning in install.packages :
  installation of package ‘httr’ had non-zero exit status

The downloaded source packages are in
	‘/tmp/RtmpzpUVJ5/downloaded_packages’
>

The error message is telling you what the problem is, you just have to read it more carefully, you are missing a system dependency (not an R package), in your topic title says that you are using Debian, so try installing it with this command from a system terminal.

sudo apt install libcurl4-openssl-dev

The same goes for the other error

2 Likes

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.