c - 安装 BRugs "C compiler cannot create executables"时出错

标签 c r gcc compiler-construction

我正在尝试在我的 Ubuntu 12.04 桌面上安装 R 库 BRugs。

> sessionInfo()
R version 2.15.1 (2012-06-22)
Platform: x86_64-pc-linux-gnu (64-bit)

但是我得到以下错误:

* installing *source* package ‘BRugs’ ...
** package ‘BRugs’ successfully unpacked and MD5 sums checked
checking for prefix by checking for OpenBUGS... /usr/bin/OpenBUGS
checking for gcc... gcc
checking whether the C compiler works... no
configure: error: in `/tmp/RtmpnNLTG1/R.INSTALL488b7635d4c0/BRugs':
configure: error: C compiler cannot create executables
See `config.log' for more details
ERROR: configuration failed for package ‘BRugs’
* removing ‘/home/myuser/lib/R/BRugs’
Warning in install.packages("BRugs") :
  installation of package ‘BRugs’ had non-zero exit status

The downloaded source packages are in
    ‘/tmp/Rtmp2ytOWn/downloaded_packages’

这里是 config.log 的链接.很难说出错误是什么,除了错误以 gcc: error: unrecognized option '-V' 开头。

如何解决此错误(并安装 BRugs)?

最佳答案

根据包说明:

Versions running on Linux and on 64-bit R under Windows are in "beta" status and less efficient.

看起来 configure 正在尝试使用 32 位可执行文件构建包(注意 -m32 标志)。最好联系软件包维护者并询问他们如何在 64 位 Ubuntu 下构建 32 位可执行文件。

关于c - 安装 BRugs "C compiler cannot create executables"时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12078117/

相关文章:

c - 同时找到最小值和最大值 : algorithm should be faster but isn't

R Markdown PowerPoint - 找不到名为 "Title Slide"的布局

regex - 在最后一个字符旁边之前拆分字符串

c++ - 在嵌套模板中使用类成员指针会导致 GCC 错误 "mismatched types Child and Base"

c++ - 继承的构造函数忽略类内初始化

c - 即使设置 PATH 变量后也是 "gcc is not recognized"。剩下什么?

c - 在 openMpi 中并行化一个函数?

c - 获取分配的内存空间的特定长度的一部分

R,在 data.frame 中找到连续时间步长的平均长度

multithreading - Ubuntu 14.04 中 Code::Blocks 上的 C++11