Rcpp Rtools installed but error message g++ not found(已安装 Rcpp Rtools 但未找到错误消息 g++)
问题描述
我已经查阅了与我的具体问题相关的现有 SO 条目,但仍然无法解决.
I have consulted existing entries on SO related to my specific issue, but still could not resolve it.
我正在尝试在我的工作机器上执行此操作,我的管理员权限有限,但我可以运行 Rtools.exe,所以我安装了它.
I am trying to do this with my machine at work, where I have limited admin rights, but I can run Rtools.exe, so I installed it.
我对 R 的设置是:
我是 RStudion 版本 0.99.902.我安装了 Rtools 版本 3.3.0.1959.
I am RStudion Version 0.99.902. I installed Rtools version 3.3.0.1959.
所有的 R、Rstudio 和 Rtools 都安装在 C:/WORK/中,这是我拥有一些有限管理员权限的地方.
All of R, Rstudio, and Rtools are installed in C:/WORK/, which is where I have some limited admin rights.
在我的系统 ENV 变量中,我设置了:
In my system ENV variable, I have set up:
当我跑步时
我明白了
当我跑步时
我明白了:
当我编译时,我得到这个错误:
When I compile, I get this error:
我的问题是:为什么 R 还在寻找 g++
My question is: why is R still looking for g++ in
我不是已经设置了 R 来查找它吗
Didn't I already set R to look for it in
即使我手动添加了
在 ENV 变量中,我仍然遇到同样的错误.(由于管理员权限,我无法在 C:/中创建 Rtools 文件夹.)
in the ENV variable, I still got the same error. (I cannot make Rtools folder in C:/ due to admin rights.)
有人遇到过这个问题吗?
Has anyone run into this specific issue?
推荐答案
路径 c:/Rtools/mingw_64/bin/
硬编码到文件 Makeconf
位于 R 安装中的某个位置(在我的情况下为 C:ProgsRR-3.4.1etcx64
),作为变量 BINPREF 的值.
The path c:/Rtools/mingw_64/bin/
is hard-coded into the file Makeconf
located somewhere in the R installation (in my case C:ProgsRR-3.4.1etcx64
), as the value of the variable BINPREF.
最简单的做法是将此路径更改为您的路径 C:/WORK/Rtools/bin
(在我的情况下是 C:/Progs/RTools/3.4/mingw_64/bin/
).这适用于我全新安装的 R-3.4.1 和 Rtools3.4,以及一个最小的示例.
The easiest thing to do is to change this path to your path C:/WORK/Rtools/bin
(in my case was C:/Progs/RTools/3.4/mingw_64/bin/
). That worked for me in a fresh installation of R-3.4.1 and Rtools3.4, and a minimal example.
这篇关于已安装 Rcpp Rtools 但未找到错误消息 g++的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!