Install two versions of rtools

1.4k Views Asked by At

I have R version 4.0.2 and Rtools40 installed in windows on the local disk C:\. I recently installed Microsoft R Client version 3.5.2, in the local disk E:\. My question is how can I install Rtools35.exe on the E:\ disk without interfering with the Rtools40 variable environment?. In other words, I want to have both versions of rtools and that they work without problems, Thanks.

When switching to R 3.5.2, rtools does not work.

library(Rcpp);
evalCpp("2 * M_PI")
Error in system(cmd, intern = !showOutput) : 'E:/Program' not found
Error in system(cmd, ignore.stderr = TRUE, intern = TRUE) : 
  'E:/Program' not found

R 4.0.2 works

library(Rcpp);
evalCpp("2 * M_PI")
6.283185
2

There are 2 best solutions below

0
On BEST ANSWER

The problem was due to the fact that Microsoft R Client version 3.5.2, was installed in a path with space E:\Program Files\Microsoft\R Client, it was solved by installing it in a path without spaces E:\Microsoft\R-Client, such as suggested in: Message error 'C:/Program' not found with Rcpp

0
On

Read the instructions at this page It should not be too hard to set up your two installation of R (4.0 and 3.6.X) so that each one queries a different .Renviron file and thus sets up a different path to the desired Rtools repository.