All package updates have non-zero exit status

Hi,

I've recently moved backwards from R4.0.2 to R3.6.3 due to some packages not being compatible with the latest version, namely Rtools.

I'm trying to install a bunch of packages but upon compilation I am getting a non-zero exit status for all packages. I also see reference to an extra '(' but I have no idea what this is about as I am running the package updates from the GUI and have not typed any code to update.

Here's a list of the packages that needed updating:
install.packages(c("boot", "cachem", "caret", "class", "cli", "cluster", "codetools", "colorspace", "curl", "dplyr", "fansi", "haven", "htmltools", "isoband", "KernSmooth", "lattice", "MASS", "Matrix", "mgcv", "mime", "nlme", "nnet", "openssl", "pROC", "ranger", "Rcpp", "readr", "slider", "spatial", "stringi", "survival", "tibble", "tzdb", "utf8", "vroom", "xfun"))

Here's an example of the first error I'm seeing:

* installing *source* package 'cachem' ...
** package 'cachem' successfully unpacked and MD5 sums checked
** using staged installation
** libs

*** arch - i386
C:/Program Files (x86)/Rtools/mingw_32/bin/gcc  -I"C:/PROGRA~1/R/R-36~1.3/include" -DNDEBUG          -O3 -Wall  -std=gnu99 -mtune=core2 -c cache.c -o cache.o
sh: -c: line 0: syntax error near unexpected token `('
sh: -c: line 0: `C:/Program Files (x86)/Rtools/mingw_32/bin/gcc  -I"C:/PROGRA~1/R/R-36~1.3/include" -DNDEBUG          -O3 -Wall  -std=gnu99 -mtune=core2 -c cache.c -o cache.o'
make: *** [C:/PROGRA~1/R/R-36~1.3/etc/i386/Makeconf:208: cache.o] Error 1
ERROR: compilation failed for package 'cachem'
* removing 'C:/Program Files/R/R-3.6.3/library/cachem'
* restoring previous 'C:/Program Files/R/R-3.6.3/library/cachem'
Warning in install.packages :
  installation of package ‘cachem’ had non-zero exit status
* installing *source* package 'cli' ...
** package 'cli' successfully unpacked and MD5 sums checked
** using staged installation
** libs

I 've tried removing some of the packages in question and re-installing but I am getting the same errors over and over.

I'd be very grateful if anyone has any suggestions of how to solve this.

Thank you.

RTools is not an R package is a separate software that you need to install in your system (not in R)

You are getting this particular error message because you are missing the x32 compiler from RTools.

I recommend you to update R to the latest version 4.1.1 (install only for the architecture you are actually going to use i.e. x32 or x64) and install RTools40

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

If you have a query related to it or one of the replies, start a new topic and refer back with a link.