Bill Amos
Bill Amos

Reputation: 21

Rcpp still cannot find Rtools

I have been through every bit of advice I can find and still I cannot get Rcpp to link successfully to Rtools, even though find_rtools() returns TRUE.

I am running Windows 7 professional, R version 3.5.1 (2018-07-02) -- "Feather Spray", Rtools35. I have installed Rtools as administrator and I have tried versions 34 and 35, with and without rebooting. My PATH variable appears to be set correctly, according to all advice. When I get the error message about needing additional tools I have tried letting Rcpp install Rtools itself but no joy. My PATH does not contain spaces and I have managed to install and use Rcpp on two other machines (and even on the current one when I was using a much earlier version of R and Rcpp - a twin machine is working fine with an old version of R).

The key error message appears to be:

> find_rtools()
[1] TRUE
> evalCpp("1+1")

make: *** No rule to make target 'file137c6efd765d.o', needed by 'sourceCpp_3.dll'. Stop. Error in sourceCpp(code = code, env = env, rebuild = rebuild, cacheDir = cacheDir, : Error 1 occurred building shared library.

but all the advice I can find for this error relate to situations where the user themself is running 'make'. I get the same error regardless of whether I run R directly from the console or through Rstudio (Version 1.1.463). Any suggestions as to diagnostics I can run / how I might solve this would win eternal gratitude.

Upvotes: 0

Views: 615

Answers (1)

Dirk is no longer here
Dirk is no longer here

Reputation: 368389

You say

I have tried letting Rcpp install Rtools itself

and I can assure you that we have no facility in Rcpp for this -- similarly find_rtools() is NOT a function of ours. Maybe you confuse Rcpp and RStudio and/or devtools.

Quick question: Is Rtools installed in C:/ ? Please try evalCpp("2+2", verbose=TRUE) to see where it goes.

Rcpp, as we document, assumes that R CMD somecommand works on your computer. Ensuring that is your responsibility as we do not have access to your computer

Upvotes: 1

Related Questions