将 php8.2-dev 包添加到我的 kubuntu 22.04 时,出现持有损坏包的错误:
root@master-at-home:/mnt/_work_sdb8/wwwroot/lar/NewsPublisher# sudo apt-get update
Hit:1 http://packages.microsoft.com/repos/code stable InRelease
Hit:2 https://dl.google.com/linux/chrome/deb stable InRelease
Hit:3 http://ua.archive.ubuntu.com/ubuntu jammy InRelease
Hit:4 https://download.docker.com/linux/ubuntu jammy InRelease
Hit:5 http://repo.mysql.com/apt/ubuntu jammy InRelease
Hit:6 https://deb.nodesource.com/node_20.x jammy InRelease
Ign:7 https://repo.mongodb.org/apt/ubuntu jammy/mongodb-org/7.0 InRelease
Hit:8 https://deb.opera.com/opera-stable stable InRelease
Hit:9 https://repo.mongodb.org/apt/ubuntu jammy/mongodb-org/7.0 Release
Hit:10 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy InRelease
Reading package lists... Done
root@master-at-home:/mnt/_work_sdb8/wwwroot/lar/NewsPublisher# sudo apt-get upgrade
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
The following packages were automatically installed and are no longer required:
appmenu-gtk-module-common jsonlint libappmenu-gtk3-parser0 php-composer-ca-bundle php-composer-metadata-minifier php-composer-pcre php-composer-semver php-composer-spdx-licenses php-composer-xdebug-handler
php-intl php-json-schema php-react-promise php-symfony-console php-symfony-process php-symfony-string php8.1-intl php8.2-mongodb
Use 'sudo apt autoremove' to remove them.
The following packages have been kept back:
libapache2-mod-php mysql-common mysql-server php-bz2 php-intl php-mbstring php-mcrypt php-mysql php-pgsql php-xml php8.2-mcrypt
0 upgraded, 0 newly installed, 0 to remove and 11 not upgraded.
root@master-at-home:/mnt/_work_sdb8/wwwroot/lar/NewsPublisher# sudo apt install php8.2-dev
Reading package lists... Done
Building dependency tree... Done
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:
libssl-dev : Depends: libssl3 (= 3.0.2-0ubuntu1) but 3.0.2-0ubuntu1.10 is to be installed
E: Unable to correct problems, you have held broken packages.
我尝试运行一个命令(我在网上找到了一个提示):
sudo aptitude install php8.2-dev
但同样的错误?
在我的操作系统中我有:
uname -a
Linux master-at-home 6.2.0-35-generic #35~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Oct 6 10:23:26 UTC 2 x86_64 x86_64 x86_64 GNU/Linux
apt list --installed libssl3
Listing... Done
libssl3/now 3.0.2-0ubuntu1.10 amd64 [installed,local]
libssl3/now 3.0.2-0ubuntu1.10 i386 [installed,local]
# dpkg -s libssl3
Package: libssl3
Status: install ok installed
Priority: required
Section: libs
Installed-Size: 5824
Maintainer: Ubuntu Developers <[email protected]>
Architecture: amd64
Multi-Arch: same
Source: openssl
Version: 3.0.2-0ubuntu1.10
Depends: libc6 (>= 2.34), debconf (>= 0.5) | debconf-2.0
Description: Secure Sockets Layer toolkit - shared libraries
This package is part of the OpenSSL project's implementation of the SSL
and TLS cryptographic protocols for secure communication over the
Internet.
.
It provides the libssl and libcrypto shared libraries.
Homepage: https://www.openssl.org/
Original-Maintainer: Debian OpenSSL Team <[email protected]>
如何缓解这个问题?
更新区块:
我尝试在 root 下运行命令:
master@master-at-home:/mnt/_work_sdb8/wwwroot/lar/WebsocketLaravel10$ sudo -s
[sudo] password for master:
root@master-at-home:/mnt/_work_sdb8/wwwroot/lar/WebsocketLaravel10# apt policy php8.2-common
php8.2-common:
Installed: 8.2.15-1+ubuntu22.04.1+deb.sury.org+1
Candidate: 8.2.15-1+ubuntu22.04.1+deb.sury.org+1
Version table:
*** 8.2.15-1+ubuntu22.04.1+deb.sury.org+1 500
500 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy/main amd64 Packages
100 /var/lib/dpkg/status
但仍然出现 libssl3 依赖错误:
root@master-at-home:/mnt/_work_sdb8/wwwroot/lar/WebsocketLaravel10# apt policy php8.2-dev
php8.2-dev:
Installed: (none)
Candidate: 8.2.15-1+ubuntu22.04.1+deb.sury.org+1
Version table:
8.2.15-1+ubuntu22.04.1+deb.sury.org+1 500
500 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy/main amd64 Packages
root@master-at-home:/mnt/_work_sdb8/wwwroot/lar/WebsocketLaravel10# sudo apt install php8.2-dev
Reading package lists... Done
Building dependency tree... Done
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:
libssl-dev : Depends: libssl3 (= 3.0.2-0ubuntu1) but 3.0.2-0ubuntu1.10 is to be installed
更新区块 # 2:
apt policy php8.2-dev
php8.2-dev:
Installed: (none)
Candidate: 8.2.15-1+ubuntu22.04.1+deb.sury.org+1
Version table:
8.2.15-1+ubuntu22.04.1+deb.sury.org+1 500
500 https://ppa.launchpadcontent.net/ondrej/php/ubuntu jammy/main amd64 Packages
?