linux - 在 ubuntu 上安装以前版本的 R 时出错

标签 linux r installation

我的计算机 (Linux) 上安装了 R 3.4.1.1。

我想安装 R 版本 2.14.1,因为 Rmosek 包在新版本中不起作用。

我已经从 Cran 下载了 R-2.14.2.tar.gz。

我的问题是我不明白安装说明,

它说解压 R 源并转到顶层目录并发出以下命令:

./configure

make

我在终端中写了以下内容:

tar -zxvf R-2.14.2.tar.gz

cd Downloads 

cd R-2.14.2

./configure

它运行但最后给出错误:

configure: error: --with-x=yes (default) and X11 headers/libs are not available

make

它给出了错误:

make: *** No targets specified and no makefile found.  Stop.

该文件说明如果我的 make 不叫 `make',请将环境变量 MAKE 设置为 它的名称,并在这些说明中通篇使用该名称。我真的不知道我应该怎么做,因为我是 Linux 新手。

还有其他说明更详细的说明吗?非常感谢您的帮助或指导。

问候,

志摩。

最佳答案

这在 R 安装和管理指南中有详细的回答, http://cran.r-project.org/doc/manuals/R-admin.html#Essential-programs-and-libraries

Unless you do not want to view graphs on-screen (or use a Mac) you need ‘X11’ installed, including its headers and client libraries. For recent Fedora distributions it means (at least) RPMs ‘libX11’, ‘libX11-devel’, ‘libXt’ and ‘libXt-devel’. On Debian we recommend the meta-package ‘xorg-dev’. If you really do not want these you will need to explicitly configure R without X11, using --with-x=no.

更具体地说,对于 Ubuntu,这意味着:

sudo apt-get install xorg-dev

然后继续编译安装R。

关于linux - 在 ubuntu 上安装以前版本的 R 时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20752307/

相关文章:

linux - 无法使用 sysctl 更改每个进程的最大打开文件数

r - 为什么我们不能使用 .作为带有 %>% 的匿名函数中的参数

windows - 使用管理权限在 NSIS 中执行 Execwait

python - 如何在不创建新环境的情况下从一个文件在 conda 中安装多个包?

java - Windows 7 上的 apache ant 安装

linux - 为什么 grep 给出搜索模式错误,即 grep : <some pattern>: No such file or directory

linux - 如何恢复丢失的 Redis 服务

linux - Crontab 作业未针对具体值运行;但执行相对时间值

r - 错误 : The animation object does not specify a save_animation method

r - R中散点图标准差的计算