Hello - I haven't used R/RStudio on my laptop for ~8 months or so, so my installations were quite out of date. I have just upgraded to R 4.1.2
and the newest version of RStudio and am trying to reinstall all my required packages, but am running into problems.
First, I tried to reinstall tidyverse
- however, it had trouble installing the package cli
:
* installing *source* package 'cli' ...
** package 'cli' successfully unpacked and MD5 sums checked
** using staged installation
** libs
*** arch - i386
"c:/rtools40/mingw32/bin/"gcc -I"C:/PROGRA~1/R/R-41~1.2/include" -DNDEBUG -O2 -Wall -std=gnu99 -mfpmath=sse -msse2 -mstackrealign -c ansi.c -o ansi.o
sh: c:/rtools40/mingw32/bin/gcc: No such file or directory
make: *** [C:/PROGRA~1/R/R-41~1.2/etc/i386/Makeconf:238: ansi.o] Error 127
ERROR: compilation failed for package 'cli'
* removing 'C:/Users/rlawr/OneDrive/Documents/R/win-library/4.1/cli'
Warning in install.packages :
installation of package ‘cli’ had non-zero exit status
This is the only thing stopping me from loading other packages; if, for example, I try to attach Tidyverse
, I get this:
> library(tidyverse)
Error: package or namespace load failed for ‘tidyverse’:
.onAttach failed in attachNamespace() for 'tidyverse', details:
call: loadNamespace(x)
error: there is no package called ‘cli’
I wanted to try installing from, say, GitHub or elsewhere with devtools
, but in a cruel catch-22, that also requires cli
...:
> library(devtools)
Error: package or namespace load failed for ‘devtools’ in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]):
there is no package called ‘cli’
I am already running in Administrator, although my desktop where I do the majority of my work in R does not require this and they were (initially) set up almost identically - any help would be greatly appreciated!
EDIT: Obviously it is having trouble finding gcc
in the rtools40 folder, which I simply assumed was present since I installed it - however, I have just noticed that the folder is actually called simply Rtools
. I'm reticent to rename it incase it breaks other package installations, but I'll give this a try now and see what explodes.