For example, I am able to use install.packages()
to install dplyr
, but when I try to load it into the session using library()
, the following happens:
install.packages('dplyr')
Installing package into ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6’
(as ‘lib’ is unspecified)
also installing the dependencies ‘fansi’, ‘purrr’, ‘cli’, ‘utf8’, ‘ellipsis’, ‘glue’, ‘lifecycle’, ‘magrittr’, ‘rlang’, ‘tibble’, ‘tidyselect’, ‘vctrs’, ‘pillar’
trying URL 'https://cloud.r-project.org/src/contrib/fansi_0.5.0.tar.gz'
Content type 'application/x-gzip' length 301724 bytes (294 KB)
==================================================
downloaded 294 KB
trying URL 'https://cloud.r-project.org/src/contrib/purrr_0.3.4.tar.gz'
Content type 'application/x-gzip' length 375062 bytes (366 KB)
==================================================
downloaded 366 KB
trying URL 'https://cloud.r-project.org/src/contrib/cli_3.0.1.tar.gz'
Content type 'application/x-gzip' length 225589 bytes (220 KB)
==================================================
downloaded 220 KB
trying URL 'https://cloud.r-project.org/src/contrib/utf8_1.2.2.tar.gz'
Content type 'application/x-gzip' length 240327 bytes (234 KB)
==================================================
downloaded 234 KB
trying URL 'https://cloud.r-project.org/src/contrib/ellipsis_0.3.2.tar.gz'
Content type 'application/x-gzip' length 8066 bytes
==================================================
downloaded 8066 bytes
trying URL 'https://cloud.r-project.org/src/contrib/glue_1.4.2.tar.gz'
Content type 'application/x-gzip' length 99049 bytes (96 KB)
==================================================
downloaded 96 KB
trying URL 'https://cloud.r-project.org/src/contrib/lifecycle_1.0.0.tar.gz'
Content type 'application/x-gzip' length 83389 bytes (81 KB)
==================================================
downloaded 81 KB
trying URL 'https://cloud.r-project.org/src/contrib/magrittr_2.0.1.tar.gz'
Content type 'application/x-gzip' length 265580 bytes (259 KB)
==================================================
downloaded 259 KB
trying URL 'https://cloud.r-project.org/src/contrib/rlang_0.4.11.tar.gz'
Content type 'application/x-gzip' length 861727 bytes (841 KB)
==================================================
downloaded 841 KB
trying URL 'https://cloud.r-project.org/src/contrib/tibble_3.1.4.tar.gz'
Content type 'application/x-gzip' length 737787 bytes (720 KB)
==================================================
downloaded 720 KB
trying URL 'https://cloud.r-project.org/src/contrib/tidyselect_1.1.1.tar.gz'
Content type 'application/x-gzip' length 92088 bytes (89 KB)
==================================================
downloaded 89 KB
trying URL 'https://cloud.r-project.org/src/contrib/vctrs_0.3.8.tar.gz'
Content type 'application/x-gzip' length 782608 bytes (764 KB)
==================================================
downloaded 764 KB
trying URL 'https://cloud.r-project.org/src/contrib/pillar_1.6.2.tar.gz'
Content type 'application/x-gzip' length 1130321 bytes (1.1 MB)
==================================================
downloaded 1.1 MB
trying URL 'https://cloud.r-project.org/src/contrib/dplyr_1.0.7.tar.gz'
Content type 'application/x-gzip' length 852103 bytes (832 KB)
==================================================
downloaded 832 KB
* installing *source* package ‘fansi’ ...
** package ‘fansi’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
sh: 1: make: not found
Warning in system(cmd) : error in running command
ERROR: compilation failed for package ‘fansi’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/fansi’
Warning in install.packages :
installation of package ‘fansi’ had non-zero exit status
* installing *source* package ‘utf8’ ...
** package ‘utf8’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
sh: 1: make: not found
Warning in system(cmd) : error in running command
ERROR: compilation failed for package ‘utf8’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/utf8’
Warning in install.packages :
installation of package ‘utf8’ had non-zero exit status
* installing *source* package ‘glue’ ...
** package ‘glue’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
sh: 1: make: not found
Warning in system(cmd) : error in running command
ERROR: compilation failed for package ‘glue’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/glue’
Warning in install.packages :
installation of package ‘glue’ had non-zero exit status
* installing *source* package ‘magrittr’ ...
** package ‘magrittr’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
sh: 1: make: not found
Warning in system(cmd) : error in running command
ERROR: compilation failed for package ‘magrittr’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/magrittr’
Warning in install.packages :
installation of package ‘magrittr’ had non-zero exit status
* installing *source* package ‘rlang’ ...
** package ‘rlang’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
sh: 1: make: not found
Warning in system(cmd) : error in running command
ERROR: compilation failed for package ‘rlang’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/rlang’
Warning in install.packages :
installation of package ‘rlang’ had non-zero exit status
ERROR: dependencies ‘magrittr’, ‘rlang’ are not available for package ‘purrr’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/purrr’
Warning in install.packages :
installation of package ‘purrr’ had non-zero exit status
ERROR: dependency ‘glue’ is not available for package ‘cli’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/cli’
Warning in install.packages :
installation of package ‘cli’ had non-zero exit status
ERROR: dependency ‘rlang’ is not available for package ‘ellipsis’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/ellipsis’
Warning in install.packages :
installation of package ‘ellipsis’ had non-zero exit status
ERROR: dependencies ‘glue’, ‘rlang’ are not available for package ‘lifecycle’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/lifecycle’
Warning in install.packages :
installation of package ‘lifecycle’ had non-zero exit status
ERROR: dependencies ‘ellipsis’, ‘glue’, ‘rlang’ are not available for package ‘vctrs’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/vctrs’
Warning in install.packages :
installation of package ‘vctrs’ had non-zero exit status
ERROR: dependencies ‘ellipsis’, ‘glue’, ‘purrr’, ‘rlang’, ‘vctrs’ are not available for package ‘tidyselect’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/tidyselect’
Warning in install.packages :
installation of package ‘tidyselect’ had non-zero exit status
ERROR: dependencies ‘cli’, ‘ellipsis’, ‘fansi’, ‘lifecycle’, ‘rlang’, ‘utf8’, ‘vctrs’ are not available for package ‘pillar’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/pillar’
Warning in install.packages :
installation of package ‘pillar’ had non-zero exit status
ERROR: dependencies ‘ellipsis’, ‘fansi’, ‘lifecycle’, ‘magrittr’, ‘pillar’, ‘rlang’, ‘vctrs’ are not available for package ‘tibble’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/tibble’
Warning in install.packages :
installation of package ‘tibble’ had non-zero exit status
ERROR: dependencies ‘ellipsis’, ‘glue’, ‘lifecycle’, ‘magrittr’, ‘rlang’, ‘tibble’, ‘tidyselect’, ‘vctrs’, ‘pillar’ are not available for package ‘dplyr’
* removing ‘/home/ubuntu/R/x86_64-pc-linux-gnu-library/3.6/dplyr’
Warning in install.packages :
installation of package ‘dplyr’ had non-zero exit status
The R version is 3.6.3, I installed it using the release for Linux x86_64-pc-linux file, my version of Ubuntu is 20.04 and Rstudio is 1.4.1717.
Any help would be highly appreciated
CodePudding user response:
You need to have make
installed.
Try running:
sudo apt-get install build-essential