0

I need to install Rtools but I'm not having success.

When I run this it works

library(devtools)
find_rtools()
[1] TRUE

when I load the library, it also works fine. But when I run my code that needs rtools, I get:

Error in sourceCpp(code = code, env = env, rebuild = rebuild, cacheDir = cacheDir,  : 
  Error 1 occurred building shared library.
WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding:

https://cran.rstudio.com/bin/windows/Rtools/

and when I try to install rtools I get this:

Warning in install.packages :
  package ‘Rtools’ is not available (for R version 3.5.2)

Solution

Setting the path solved the problem. thank you @red_quark

Rtools is not being detected from RStudio

Hugo Silva
  • 199
  • 9
  • I think, these topics can help you. Check if you correctly installed path of Rtools. https://stackoverflow.com/questions/33103203/rtools-is-not-being-detected-from-rstudio/44035904#44035904, https://stackoverflow.com/questions/17619185/rcpp-cant-find-rtools-error-1-occurred-building-shared-library – red_quark Dec 10 '19 at 00:55
  • Setting the paths solved the issue. thanks @red_quark! – Hugo Silva Dec 10 '19 at 09:35

0 Answers0