我已经尝试将我的Ubuntu服务器的PHP版本升级到5.4了很长一段时间。
首先我要跑:
sudo add-apt-repository ppa:ondrej/php5-oldstable
但我明白了:
sudo: add-apt-repository: command not found
所以我运行这个:
sudo apt-get install python-software-properties
然后我明白了:
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:
python-software-properties : Depends: python-apt (>= 0.6.20ubuntu16) but it is not going to be installed
Depends: unattended-upgrades but it is not going to be installed
E: Broken packages
所以,我正在尝试安装python-apt:
sudo apt-get install python-apt
还有一条错误信息:
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:
python-apt : Depends: libapt-inst-libc6.10-6-1.1
Depends: libapt-pkg-libc6.10-6-4.8
E: Broken packages
所以,我尝试安装libapt-inst-libc6.10-6-1.1:
sudo apt-get install libapt-inst-libc6.10-6-1.1
我得到了:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'apt-utils' instead of 'libapt-inst-libc6.10-6-1.1'
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:
apt-utils : Depends: libapt-pkg-libc6.10-6-4.8
E: Broken packages
它一直在继续。我不知道该怎么办。请帮忙!
答案 0 :(得分:0)
干杯,
RonAtomics
P.S。我知道它没有意义,但是,你试过再次尝试所有的命令吗?...... CentOS很傻,Ubuntu可能也是如此,我想我会提到它。
P.S.S。这是针对python的Ubuntu 12.04和14.04的不同PPA。 http://ubuntuhandbook.org/index.php/2014/05/install-python-3-3-5-or-3-4-via-ppa-in-ubuntu-14-04-12-04/