在Ubuntu 16.04上出现了Octave依赖问题。

我正在尝试在新安装的Ubuntu 16.04上安装Octave。所以我尝试了以下命令:
sudo apt-add-repository ppa:octave/stable
sudo apt-get update
sudo apt-get install octave

在执行“sudo apt-get update”之后,我遇到了以下错误和警告:
Err:9 http://ppa.launchpad.net/octave/stable/ubuntu xenial/main amd64 Packages                                                      
  404  Not Found
Err:10 http://ppa.launchpad.net/octave/stable/ubuntu xenial/main i386 Packages                                                      
  404  Not Found

W: The repository 'http://ppa.launchpad.net/octave/stable/ubuntu xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch http://ppa.launchpad.net/octave/stable/ubuntu/dists/xenial/main/binary-amd64/Packages  404  Not Found
E: Failed to fetch http://ppa.launchpad.net/octave/stable/ubuntu/dists/xenial/main/binary-i386/Packages  404  Not Found
E: Some index files failed to download. They have been ignored, or old ones used instead.

在执行完“sudo apt-get install octave”之后:
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:
 octave : Depends: libarpack2 (>= 2.1) but it is not going to be installed
          Depends: libcholmod3.0.6 but it is not going to be installed
          Depends: liboctave3 (= 4.0.0-3ubuntu9) but it is not going to be installed
          Depends: libosmesa6 (>= 10.2~) but it is not going to be installed
          Recommends: libopenblas-base but it is not going to be installed or
                      libatlas3-base but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

在这之后,当我尝试执行 'sudo apt-get -f install' 命令时:
Reading package lists... Done
Building dependency tree       
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

我尝试安装依赖项以便编译源代码,但出现了类似的错误(sudo apt-get install libarpack2):
Reading package lists... Done
Building dependency tree       
Reading state information... Done
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:
 libarpack2 : Depends: libgfortran3 (>= 4.6) but it is not going to be installed
              Depends: liblapack3 but it is not going to be installed or
                       liblapack.so.3
E: Unable to correct problems, you have held broken packages.

现在我能做什么?

1那个PPA似乎没有包含Xenial版本的构建,可能是因为Xenial的universe仓库中已经有了4.0.0版本 - 你真的需要一个PPA吗? - steeldriver
大多数服务器(包括土耳其的)都还没有准备好。更换服务器将解决您的问题。 - al0s
也与http://askubuntu.com/questions/765518/ubuntu-16-04-broken-packages-after-fresh-install重复。 - al0s
1个回答

16.04是新版本,所有软件包都还没有准备好在所有服务器上使用。使用主服务器下载软件包将解决您的问题。
1. 系统设置 2. 软件和更新 3. 在“下载自”部分选择“主服务器”

非常荣幸。你应该点击“接受答案”,让其他人知道它起作用了。 - al0s