linux - r-base-dev 由于依赖关系不会安装

标签 linux r ubuntu

我是 stackoverflow、R 和 Ubuntu 的新手……开始吧。我有一台运行带有 Oracle VM Virtual box 的虚拟 Ubuntu 机器的 Windows 机器。我的 Ubuntu 是 32 位的,是作为 Coursera 数据挖掘类(class)的一部分安装的。

我正在尝试让 word2vec.c 和 word2phrase.c 通过系统命令编译并在 R 中使用。我做了很多研究,发现 Windows 机器不支持 pthread.h,所以我想我会在 Ubuntu 虚拟机上安装 R 来解决这个问题。我已按照说明在此处找到的 Ubuntu 上安装 R:http://sites.psu.edu/theubunturblog/installing-r-in-ubuntu/当我使用 sudo apt-get install r-base 安装基础 R 包时它工作正常,但是当我尝试使用 sudo apt-get install r 安装 r-base-dev 应用程序时-base-dev 我收到以下错误:

Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 r-base-dev : Depends: build-essential but it is not going to be installed
              Depends: cdbs but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

我已尝试安装 build-essential,但我收到如下警告/错误消息:

Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 build-essential : Depends: dpkg-dev (>= 1.13.5) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

我去尝试安装 dpkg-dev,它是依赖项,直到我遇到这个警告的死胡同:

Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 dpkg-dev : Depends: libdpkg-perl (= 1.17.5ubuntu5) but 1.17.5ubuntu5.3 is to be installed
            Recommends: build-essential but it is not going to be installed
            Recommends: fakeroot but it is not going to be installed
            Recommends: libalgorithm-merge-perl but it is not going to be installed

这里似乎有循环逻辑,它推荐 build-essntial,但我正在尝试安装 libdpkg-perl,这样我就可以安装 build-essential...我一定是在这里遗漏了一些东西,请帮忙!

我已经阅读了足够多的资料,知道我需要 R 开发工具包才能在 R 中使用 install.packages,所以如果我不能解决这个问题,我将无法在我的程序中安装或包含任何标准库R 脚本。

最佳答案

最后的问题是我下载的 Ubuntu 镜像损坏了。我重新下载了它,问题消失了。

关于linux - r-base-dev 由于依赖关系不会安装,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32798472/

相关文章:

r - 从 github 安装 knitr

java - JNotify 何时通知文件的创建

php - 在 Ubuntu 中使用 php exec 函数不起作用

python - 从pyttsx python中的文本文件中获取数据

linux - 使用管道和撇号时如何将 bash 命令的输出捕获到变量中?

linux - 在 crontab 中使用 wget 来运行 PHP 脚本

python - 获取 Linux 服务器中文件夹的大小

r - 如何更改在函数 (by()) 内部调用的函数 (sum()) 的选项,而不为 sum() 提供 R 中的特定参数

r - xtable大表每一页的标题?

linux - 使用本地存储库时 apt 更新失败