简体   繁体   English

install_github 中的错误:系统命令“Rcmd.exe”失败,退出状态:1,打印了标准输出和标准错误

[英]Error in install_github: System command 'Rcmd.exe' failed, exit status: 1, stdout & stderr were printed

I was trying to install the package "pgenlibr" in the github, using the command我试图在 github 中安装 package "pgenlibr",使用命令

install_github("chrchang/plink-ng", subdir="/2.0/pgenlibr") , and received the error message. install_github("chrchang/plink-ng", subdir="/2.0/pgenlibr") ,并收到错误消息。

> install_github("chrchang/plink-ng", subdir="/2.0/pgenlibr")
Downloading GitHub repo chrchang/plink-ng@HEAD
√  checking for file 'C:\Users\86137\AppData\Local\Temp\RtmpILEuSP\remotes109044a8685a\chrchang-plink-ng-73bdbc3\2.0\pgenlibr/DESCRIPTION' ...
   Warning in file.copy(pkgname, Tdir, recursive = TRUE, copy.date = TRUE) :
     problem copying .\pgenlibr\src\include to C:\Users\86137\AppData\Local\Temp\RtmpaONA8h\Rbuild2e1c6cc05dce\pgenlibr\src\include: Permission denied
   Warning in file.copy(pkgname, Tdir, recursive = TRUE, copy.date = TRUE) :
     problem copying .\pgenlibr\src\libdeflate to C:\Users\86137\AppData\Local\Temp\RtmpaONA8h\Rbuild2e1c6cc05dce\pgenlibr\src\libdeflate: Permission denied
   Warning in file.copy(pkgname, Tdir, recursive = TRUE, copy.date = TRUE) :
     problem copying .\pgenlibr\src\zstd to C:\Users\86137\AppData\Local\Temp\RtmpaONA8h\Rbuild2e1c6cc05dce\pgenlibr\src\zstd: Permission denied
    ERROR
   copying to build directory failed
Error: Failed to install 'pgenlibr' from GitHub:
  System command 'Rcmd.exe' failed, exit status: 1, stdout & stderr were printed

I have installed its required software listed on Readme, Rtools, all packages dependencies.我已经安装了自述文件、Rtools、所有软件包依赖项中列出的所需软件。 I have also tried other methods, delete all Rtmp files, run Rstudio as administrator, cancel "read only" to folder "temp" and "library" in the workpath, but gained no success.我也尝试过其他方法,删除所有Rtmp文件,以管理员身份运行Rstudio,取消工作路径中文件夹“temp”和“library”的“只读”,但没有成功。

In addition, I'm using Windows 10.另外,我使用的是 Windows 10。

How can I solve this problem?我怎么解决这个问题?

I have solve this problem on Ubuntu System.我已经在 Ubuntu 系统上解决了这个问题。 There is a similar problem when installing 'cindex', Here is the a link .安装'cindex'时也有类似的问题,这里是链接 So the reason seems to be that install_github( ) in Win10 can not deal with symlink very well.所以原因似乎是Win10中的install_github()不能很好的处理symlink。

I got the same error when I was building the source for an R package and there was a syntax error in the DESCRIPTION file.我在构建 R package 的源代码时遇到了同样的错误,并且说明文件中存在语法错误。

To solve, I removed suspected culprits from the DESCRIPTION file and it worked, so then just narrowed down to isolate the offending line (it was a typo in the person() function in my case, but causes my vary).为了解决,我从DESCRIPTION文件中删除了可疑的罪魁祸首并且它起作用了,所以然后缩小范围以隔离违规行(在我的情况下,这是person() function 中的错字,但导致我的变化)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM