R:install.package()不是在CentOS 6.5上调用编译器

时间:2016-02-19 08:53:51

标签: r linux centos

R版本:3.1.1

我想安装this package。我下载了源代码并将其放在我的主目录下。之后我运行install.packages("~/rEDM/",repos=NULL,type="source")从源代码安装。我得到的错误信息是:

Installing package into ‘/d1/dwuab/R/x86_64-redhat-linux-gnu-library/3.1’
(as ‘lib’ is unspecified)
* installing *source* package ‘rEDM’ ...
** libs
I/usr/include/R -DNDEBUG  -I/usr/local/include -I"/d1/dwuab/R/x86_64-redhat-linux-gnu-library/3.1/Rcpp/include"  -I../inst/include    -c RcppExports.cpp -o RcppExports.o
/bin/sh: I/usr/include/R: No such file or directory
make: [RcppExports.o] Error 127 (ignored)
I/usr/include/R -DNDEBUG  -I/usr/local/include -I"/d1/dwuab/R/x86_64-redhat-linux-gnu-library/3.1/Rcpp/include"  -I../inst/include    -c block_lnlp.cpp -o block_lnlp.o
/bin/sh: I/usr/include/R: No such file or directory
make: [block_lnlp.o] Error 127 (ignored)
I/usr/include/R -DNDEBUG  -I/usr/local/include -I"/d1/dwuab/R/x86_64-redhat-linux-gnu-library/3.1/Rcpp/include"  -I../inst/include    -c forecast_machine.cpp -o forecast_machine.o
/bin/sh: I/usr/include/R: No such file or directory
make: [forecast_machine.o] Error 127 (ignored)
I/usr/include/R -DNDEBUG  -I/usr/local/include -I"/d1/dwuab/R/x86_64-redhat-linux-gnu-library/3.1/Rcpp/include"  -I../inst/include    -c lnlp.cpp -o lnlp.o
/bin/sh: I/usr/include/R: No such file or directory
make: [lnlp.o] Error 127 (ignored)
I/usr/include/R -DNDEBUG  -I/usr/local/include -I"/d1/dwuab/R/x86_64-redhat-linux-gnu-library/3.1/Rcpp/include"  -I../inst/include    -c xmap.cpp -o xmap.o
/bin/sh: I/usr/include/R: No such file or directory
make: [xmap.o] Error 127 (ignored)
-L/usr/local/lib64 -o rEDM.so RcppExports.o block_lnlp.o forecast_machine.o lnlp.o xmap.o -L/usr/lib64/R/lib -lR
/bin/sh: line 2: -L/usr/local/lib64: No such file or directory
make: *** [rEDM.so] Error 127
ERROR: compilation failed for package ‘rEDM’
* removing ‘/d1/dwuab/R/x86_64-redhat-linux-gnu-library/3.1/rEDM’
Warning message:
In install.packages("~/rEDM/", repos = NULL, type = "source") :
  installation of package ‘/ghome/dwuab/rEDM/’ had non-zero exit status

这里有些东西是非常错误的,因为R根本没有调用编译器。 该软件包的作者表示,这是由于R和/或GCC配置错误造成的。

我的问题:是否有人知道问题所在?或者如何解决问题?

编辑1 :使用命令install.packages("./master.zip",repos=NULL,type="source")通过zip文件安装软件包导致以下错误消息:

Installing package into ‘/d1/dwuab/R/x86_64-redhat-linux-gnu-library/3.1’
(as ‘lib’ is unspecified)
Error in rawToChar(block[seq_len(ns)]) : 
  embedded nul in string: 'PK\003\004\n\0\0\0\0\0\x83h,H\0\0\0\0\0\0\0\0\0\0\0\0\f\0\t\0rEDM-master/UT\005\0\001Fj\x95VPK\003\004\n\0\0\0\b\0\x83h,H\x8ewq\xa1\030\0\0\0\034\0\0\0\031\0\t\0rEDM-master/.Rbuild'
Warning message:
In install.packages("./master.zip", repos = NULL, type = "source") :
  installation of package ‘./master.zip’ had non-zero exit status

编辑2 :我对该计算机没有root权限。

2 个答案:

答案 0 :(得分:1)

作为一种解决方法,我使用EasyBuild编译并安装R 3.2.1和GCC 4.9.3。整个编译和安装过程花了我几天......现在它可以工作。

答案 1 :(得分:0)