无法在 Debian 上安装 php5-imagick

无法在 Debian 上安装 php5-imagick

我正在尝试安装 Image Magick。

$ sudo apt-get install php5-imagick
The following packages have unmet dependencies.
  php5-imagick: Depends: libfontconfig1 (>= 2.8.0) but 2.6.0-3 is to be installed
                Depends: libjpeg62 (>= 6b1) but 6b-14 is to be installed
                Depends: libltdl7 (>= 2.2.6b) but it is not installable
                Depends: libmagickcore3 (>= 8:6.6.0.4) but it is not installable
                Depends: libmagickwand3 (>= 8:6.6.0.4) but it is not installable

但是当我尝试安装缺少的软件包时,出现了以下信息:

$ sudo apt-get install libfontconfig1 libjpeg62 libltdl7 libmagickcore3 libmagickwand3 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
libfontconfig1 is already the newest version.
libfontconfig1 set to manually installed.
libjpeg62 is already the newest version.
libjpeg62 set to manually installed.
Package libltdl7 is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package libltdl7 has no installation candidate

我该如何解决这些问题?

答案1

我使用 aptitude 而不是 apt-get,它提供了解决问题的选项,而不仅仅是失败。

Keep the following packages at their current version:
php5-common [5.3.8-1~dotdeb.1 (oldstable, now)]
php5-imagick [Not Installed]

^请注意,第一个“解决方案”没什么用。但是第二个解决方案奏效了:

Install the following packages:
php5-imagick [5.3.8-1~dotdeb.1 (oldstable)]

Keep the following packages at their current version:
php5-common [5.3.8-1~dotdeb.1 (oldstable, now)]

Score is -9910

Accept this solution? [Y/n/q/?] Y

相关内容