apt remove glob 安装额外的软件包

apt remove glob 安装额外的软件包

当我试图用 apt remove *poppler* --autoremove apt 卸载所有东西 poppler 时尝试安装 34 个新软件包。为什么会出现这种情况呢?

适当的输出:

# apt remove *poppler*
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'zathura-pdf-poppler' for glob '*poppler*'
Note, selecting 'ruby-poppler' for glob '*poppler*'
Note, selecting 'python2.7-poppler-dbg' for glob '*poppler*'
Note, selecting 'poppler-utils' for glob '*poppler*'
Note, selecting 'python3-poppler-qt5' for glob '*poppler*'
Note, selecting 'libpoppler-cil' for glob '*poppler*'
Note, selecting 'libpoppler-dev' for glob '*poppler*'
Note, selecting 'python2.7-poppler' for glob '*poppler*'
Note, selecting 'libpoppler-qt5-dev' for glob '*poppler*'
Note, selecting 'libpoppler-cpp0' for glob '*poppler*'
Note, selecting 'monodoc-poppler-manual' for glob '*poppler*'
Note, selecting 'libpoppler-qt5-1' for glob '*poppler*'
Note, selecting 'libpoppler-cil-dev' for glob '*poppler*'
Note, selecting 'libpoppler-glib-dev' for glob '*poppler*'
Note, selecting 'libpoppler-glib-doc' for glob '*poppler*'
Note, selecting 'libpopplerkit0' for glob '*poppler*'
Note, selecting 'qtdeclarative5-poppler-qml-plugin' for glob '*poppler*'
Note, selecting 'libpoppler-private-dev' for glob '*poppler*'
Note, selecting 'python-poppler-dbg' for glob '*poppler*'
Note, selecting 'gir1.2-poppler-0.18' for glob '*poppler*'
Note, selecting 'libpoppler-cpp-dev' for glob '*poppler*'
Note, selecting 'libpopplerkit-dev' for glob '*poppler*'
Note, selecting 'python-poppler' for glob '*poppler*'
Note, selecting 'libpoppler-cpp0v5' for glob '*poppler*'
Note, selecting 'libpoppler-glib8' for glob '*poppler*'
Note, selecting 'libpoppler79' for glob '*poppler*'
Note, selecting 'poppler-data' for glob '*poppler*'
Note, selecting 'xpoppler-utils' for glob '*poppler*'
Note, selecting 'qtdeclarative5-poppler1.0' for glob '*poppler*'
Package 'libpoppler-cpp0' is not installed, so not removed
Package 'xpoppler-utils' is not installed, so not removed
Note, selecting 'python-poppler' instead of 'python2.7-poppler'
Note, selecting 'python-poppler-dbg' instead of 'python2.7-poppler-dbg'
Note, selecting 'qtdeclarative5-poppler1.0' instead of 'qtdeclarative5-poppler-q                                                                                                                                        ml-plugin'
Package 'libpoppler-cil' is not installed, so not removed
Package 'libpoppler-cil-dev' is not installed, so not removed
Package 'libpopplerkit-dev' is not installed, so not removed
Package 'libpopplerkit0' is not installed, so not removed
Package 'monodoc-poppler-manual' is not installed, so not removed
Package 'python-poppler' is not installed, so not removed
Package 'python-poppler-dbg' is not installed, so not removed
Package 'python3-poppler-qt5' is not installed, so not removed
Package 'qtdeclarative5-poppler1.0' is not installed, so not removed
Package 'ruby-poppler' is not installed, so not removed
Package 'zathura-pdf-poppler' is not installed, so not removed
Package 'libpoppler-cpp-dev' is not installed, so not removed
Package 'libpoppler-cpp0v5' is not installed, so not removed
Package 'libpoppler-glib-doc' is not installed, so not removed
Package 'libpoppler-qt5-dev' is not installed, so not removed
The following packages were automatically installed and are no longer required:
  catdoc cups-ipp-utils fonts-crosextra-caladea fonts-crosextra-carlito
  fonts-droid-fallback fonts-linuxlibertine fonts-sil-gentium-basic gimp-data
  hplip-data inkscape-trunk-data libabw-0.1-1 libamd2 libapache-pom-java
  libbabl-0.1-0 libboost-date-time1.67.0 libboost-locale1.67.0
  libboost-thread1.67.0 libbsh-java libcamd2 libccolamd2 libcholmod3
  libclucene-contribs1v5 libclucene-core1v5 libcmis-0.5-5v5 libcolamd2
  libcommons-logging-java libcommons-parent-java libcupscgi1 libde265-0
  libe-book-0.1-1 libemf1 libeot0 libepub0 libepubgen-0.1-1 libetonyek-0.1-1
  libexiv2-14 libfontembed1 libfreehand-0.1-1 libgegl-0.4-0 libgegl-common
  libgexiv2-2 libgimp2.0 libgs9-common libheif1 libhpmud0 libijs-0.35
  libjbig2dec0 libmetis5 libmhash2 libmspub-0.1-1 libmwaw-0.3-3
  libmypaint-1.3-0 libmypaint-common libmythes-1.2-0 libneon27-gnutls
  libodfgen-0.1-1 liborcus-0.13-0 libpagemaker-0.0-0 libplot2c2
  libpstoedit0c2a libqpdf21 libraptor2-0 librasqal3 libraw16 librdf0
  libreoffice-java-common libsane-hpaio libsuitesparseconfig5 libtumbler-1-0
  libumfpack5 libwps-0.4-4 libxmlsec1 libxmlsec1-nss libyajl2 lp-solve
  python-scour python3-olefile python3-pexpect python3-pil python3-ptyprocess
  python3-renderpm python3-reportlab python3-reportlab-accel python3-scour
  qpdf scour tumbler-common
Use 'apt autoremove' to remove them.
The following additional packages will be installed:
  colord colord-data foomatic-filters libbsd0:i386 libcairo2:i386 libcolorhug2
  libexpat1:i386 libfontconfig1:i386 libfreetype6:i386 libjbig0:i386
  libjpeg-turbo8:i386 libjpeg8:i386 liblcms2-2:i386 liblzma5:i386
  libnspr4:i386 libnss3:i386 libpaps0 libpixman-1-0:i386 libpng16-16:i386
  libpoppler79:i386 libsqlite3-0:i386 libtiff5:i386 libuuid1:i386
  libx11-6:i386 libxau6:i386 libxcb-render0:i386 libxcb-shm0:i386 libxcb1:i386
  libxdmcp6:i386 libxext6:i386 libxrender1:i386 paps poppler-utils:i386
  zlib1g:i386
Suggested packages:
  colord-sensor-argyll
Recommended packages:
  ghostscript poppler-data:i386
The following packages will be REMOVED:
  bluez-cups cups cups-core-drivers cups-filters cups-filters-core-drivers
  cups-x2go fig2dev ghostscript ghostscript-x gimp gir1.2-poppler-0.18 hplip
  inkscape-trunk libgs9 libkf5filemetadata-bin libpoppler-dev
  libpoppler-glib-dev libpoppler-glib8 libpoppler-private-dev libpoppler-qt5-1
  libpoppler79 libreoffice libreoffice-avmedia-backend-gstreamer
  libreoffice-base libreoffice-base-core libreoffice-base-drivers
  libreoffice-calc libreoffice-core libreoffice-draw libreoffice-impress
  libreoffice-librelogo libreoffice-math libreoffice-nlpsolver
  libreoffice-ogltrans libreoffice-report-builder
  libreoffice-report-builder-bin libreoffice-script-provider-bsh
  libreoffice-script-provider-js libreoffice-script-provider-python
  libreoffice-sdbc-postgresql libreoffice-wiki-publisher libreoffice-writer
  poppler-data poppler-utils printer-driver-hpcups printer-driver-pnm2ppa
  printer-driver-postscript-hp printer-driver-ptouch printer-driver-pxljr
  printer-driver-sag-gdi printer-driver-splix pstoedit python3-uno tumbler
  xubuntu-core
The following NEW packages will be installed:
  colord colord-data foomatic-filters libbsd0:i386 libcairo2:i386 libcolorhug2
  libexpat1:i386 libfontconfig1:i386 libfreetype6:i386 libjbig0:i386
  libjpeg-turbo8:i386 libjpeg8:i386 liblcms2-2:i386 liblzma5:i386
  libnspr4:i386 libnss3:i386 libpaps0 libpixman-1-0:i386 libpng16-16:i386
  libpoppler79:i386 libsqlite3-0:i386 libtiff5:i386 libuuid1:i386
  libx11-6:i386 libxau6:i386 libxcb-render0:i386 libxcb-shm0:i386 libxcb1:i386
  libxdmcp6:i386 libxext6:i386 libxrender1:i386 paps poppler-utils:i386
  zlib1g:i386
0 upgraded, 34 newly installed, 55 to remove and 0 not upgraded.
Need to get 7,361 kB of archives.
After this operation, 312 MB disk space will be freed.
Do you want to continue? [Y/n] 

答案1

在默认的 Ubuntu 桌面安装中,有很多依赖于libpoppler或(直接或间接)的软件包。poppler-utils

删除popple-utils意味着删除cups-filter依赖于它的内容。

printer-driver-foo2zjs取决于,cups-filters | foomatic-filters因此只要您安装foomatic-filters不依赖于的,就可以保留它poppler-utils

poppler-utils 推荐 colord并且您可能已经配置了 apt 来安装推荐自动(默认情况下)。它还推荐poppler-utils。您已要求删除该poppler-utils软件包,但仍可以安装它的 i386 版本。

最后,apt尝试满足您的请求,同时最大限度地减少损害(要删除的其他软件包的数量),但在这种情况下,它会导致次优选择,因为您最终会安装相同的软件包,但处于外部体系结构中。

还有许多其他可能的替代方法来解决这些依赖性问题。

我个人总是使用aptitude包管理,因为它可以让我选择如何解决依赖冲突。

aptitude,我将默认视图设置为平坦的(在选项->首选项中,还勾选“前进到下一个条目”选项),那么您可以更轻松地过滤包。例如,通过按l(小写L)限制视图,输入~i poppler,您将获得名称包含 的已安装软件包的列表poppler

然后,您可以卸载 ( -) 或清除 ( _) 每个包,当您这样做时,您会注意到aptitude冲突标记(并且某些包可能会变成红色)。然后,您可以检查冲突 ( e) 并在多种可能的解决方案中进行选择。您还可以通过批准或拒绝个人选择来影响决议(例如删除该包,安装那个包...)。

另请注意,*poppler*您的 中的apt remove *poppler* --autoremove应该已被引用。*poppler*是一个外壳球体。例如,如果当前目录中有一个popplering文件,它会被 shell 扩展,因此您最终会运行apt remove popplering --autoremove.

某些 shell,如 csh、tcsh、fish、zsh(或bash -O failglob)可以让您通过报告错误来认识到自己的错误No match

相关内容