我正在尝试安装 R 包插入符
R -e "install.packages('caret', repos='http://cran.rstudio.com/')"
在 Amazon Linux AMI 上,但依赖项 RcppEigen、lme4、BradleyTerry2 失败。
Warning messages:
1: In install.packages("caret", repos = "http://cran.rstudio.com/") : installation of package ‘RcppEigen’ had non-zero exit status
2: In install.packages("caret", repos = "http://cran.rstudio.com/") : installation of package ‘lme4’ had non-zero exit status
3: In install.packages("caret", repos = "http://cran.rstudio.com/") : installation of package ‘BradleyTerry2’ had non-zero exit status
4: In install.packages("caret", repos = "http://cran.rstudio.com/") : installation of package ‘caret’ had non-zero exit status
当我尝试安装 RcppEigen 时,我得到(以及其他详细信息):
/usr/bin/ld: cannot find -lRlapack
/usr/bin/ld: cannot find -lRblas
collect2: ld returned 1 exit status
make: *** [RcppEigen.so] Error 1
ERROR: compilation failed for package ‘RcppEigen’
* removing ‘/usr/lib64/R/library/RcppEigen’
我的环境
Amazon Linux version 2015.03
Linux version 3.4.37-40.44.amzn1.x86_64 (mockbuild@gobi-build-31005) (gcc version 4.6.3 20120306 (Red Hat 4.6.3-2) (GCC) ) #1 SMP Thu Mar 21 01:17:08 UTC 2013
这似乎是否与 Red Hat 与 Ubuntu 有关,但我在这里或其他地方找不到任何答案。
最佳答案
您需要启用 Extra Packages for Enterprise Linux (EPEL) 存储库。
要执行此操作:
修改/etc/yum.repos.d/epel.repo
。在标记为 [epel]
的部分下,将 enabled=0
更改为 enabled=1
。
要临时启用 EPEL 6 存储库,请使用 yum 命令行选项 --enablerepo=epel
。
有关更多信息,请参阅official documentation
关于linux - 在 AWS Red Hat Linux 上安装插入符号时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31885561/