![22-04:如何为 fslint 安装 python-gtk2 和 python-glade-2](https://linux22.com/image/946378/22-04%EF%BC%9A%E5%A6%82%E4%BD%95%E4%B8%BA%20fslint%20%E5%AE%89%E8%A3%85%20python-gtk2%20%E5%92%8C%20python-glade-2.png)
我需要 python-gtk2 和 python-glade-2 用于旧应用程序,但是当我运行 dpkg -i 时,我得到了这个(翻译),说我错过了 python ???
sudo dpkg -i python-gtk2_2.24.0-5.1ubuntu2_amd64.deb python-glade2_2.24.0-5.1ubuntu2_amd64.deb
Selecting packet python-gtk2 previously deselected.
(reading database... 364958 files et directories already installed.)
Preparation to unpacking python-gtk2_2.24.0-5.1ubuntu2_amd64.deb ...
Unpacking python-gtk2 (2.24.0-5.1ubuntu2) ...
Selecting packet python-glade2 previously deselected.
Preparation to unpacking python-glade2_2.24.0-5.1ubuntu2_amd64.deb ...
Unpacking python-glade2 (2.24.0-5.1ubuntu2) ...
dpkg: dependencies problems prevent configuration of python-gtk2 :
python-gtk2 depends on python (<< 2.8) ; although :
Packet python is not installed.
python-gtk2 depend on python (>= 2.7) ; although :
Package python is not installed.
python-gtk2 depend on python:any (>= 2.6.6-7~) ; although :
Package python is not installed.
dpkg: error when processing python-gtk2 package (--install) :
dependencies problems - left unconfigured
dpkg: dependencies problems prevent configuration of python-glade2 :
python-glade2 depends on python (<< 2.8) ; although :
Package python is not installed.
python-glade2 depends on python (>= 2.7) ; although :
Package python is not installed.
python-glade2 depends on python-gtk2 (= 2.24.0-5.1ubuntu2) ; although :
Package python-gtk2 is not yet configured.
dpkg: error when processing python-glade2 package (--install) :
dependencies problems - left unconfigured
Errors were encountered when running :
python-gtk2
python-glade2
虽然 :
sudo apt list python2.7 --installed
Listing... Done
python2.7/jammy,now 2.7.18-13ubuntu1 amd64 [installed]
请告诉我那里出了什么问题。几天前我在 debian11 上成功了,我只需要运行
sudo apt -f install
来解决问题。相反,当我apt-f 安装这里,ubuntu 想要删除这 2 个包而不是修复安装。
谢谢你的提示。我知道这确实不是标准做法。
答案1
虽然这不太优雅,但现在我们在 Ubuntu 软件中心有了 fslint-unofficial snap
答案2
请参阅 Just_Alex 的回答如何在 Ubuntu 22.04 上安装 Mendeley?其开头是“在 Ubuntu 22.04 上安装 Mendeley 时遇到以下错误:”。
他引用了https://serverfault.com/a/383958从 python-gtk2_2.24.0-5.1ubuntu2_amd64.deb 中删除python
依赖项。 您应该也可以对 python-glade2_2.24.0-5.1ubuntu2_amd64.deb 包执行相同的操作。
一旦您删除了依赖项并重新打包.debs,您就应该能够继续安装/运行旧的应用程序。