我在 debian9 上运行并使用ppa:ondrej/php
存储库,但无法安装 php7.1。也不安装缺少的依赖项。当我尝试安装它时,apt install php7.1-gd
我遇到了这个错误。
apt-get install php7.1-gd
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:
php7.1-gd : Depends: libgd3 (>= 2.1.1) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
这是我尝试安装时发生的错误libgd3
apt install libgd3
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:
libgd3 : Depends: libc6 (>= 2.29) but 2.24-11+deb9u4 is to be installed
Depends: libfontconfig1 (>= 2.12.6) but 2.11.0-6.7+b1 is to be installed
Depends: libjpeg8 (>= 8c) but it is not installable
E: Unable to correct problems, you have held broken packages.
不要在 Debian 9 上使用 PPA,请使用适当的存储库,如Ondrej
README.txt
中所述:这将允许您安装
php7.1-gd
Debian 9 中可以满足的依赖项。你可以从这里找到包:
http://ftp.br.debian.org/debian/pool/main/libj/libjpeg-turbo