我从默认存储库安装了 boost 库 1.58,并从源代码安装了旧版本。现在我想删除 boost 1.58。
我首先删除了libboost-all-dev
软件包,但仍然有四个软件包安装着,其中两个我分别删除了,还有两个我就是无法删除。这两个软件包是:libboost-system1.58.0
和libboost-filesystem1.58.0
。每当我这样做时,sudo apt-get --purge remove libboost-system1.58.0
都会出现未满足的依赖关系错误,这与有关qt
,我不知道它为什么与有关。
错误输出如下所示:
The following packages have unmet dependencies:
liboxideqt-qmlplugin : Depends: libqt5quick5 (>= 5.0.2) but it is not going to be installed or
libqt5quick5-gles (>= 5.0.2) but it is not going to be installed
liboxideqtcore0 : Depends: libqt5gui5 (>= 5.4.0) but it is not going to be installed or
libqt5gui5-gles (>= 5.4.0) but it is not going to be installed
liboxideqtquick0 : Depends: libqt5gui5 (>= 5.0.2) but it is not going to be installed or
libqt5gui5-gles (>= 5.0.2) but it is not going to be installed
Depends: libqt5quick5 (>= 5.2.0) but it is not going to be installed or
libqt5quick5-gles (>= 5.2.0) but it is not going to be installed
libqmenumodel0 : Depends: libqt5gui5 (>= 5.0.2) but it is not going to be installed or
libqt5gui5-gles (>= 5.0.2) but it is not going to be installed
libqt5multimedia5 : Depends: libqt5gui5 (>= 5.2.0) but it is not going to be installed or
libqt5gui5-gles (>= 5.2.0) but it is not going to be installed
libqt5multimediaquick-p5 : Depends: libqt5gui5 (>= 5.0.2) but it is not going to be installed or
libqt5gui5-gles (>= 5.0.2) but it is not going to be installed
Depends: libqt5quick5 (>= 5.4.0) but it is not going to be installed or
libqt5quick5-gles (>= 5.4.0) but it is not going to be installed
libqt5x11extras5 : Depends: libqt5gui5 (>= 5.0.2) but it is not going to be installed or
libqt5gui5-gles (>= 5.0.2) but it is not going to be installed
libubuntugestures5 : Depends: libqt5gui5 (>= 5.0.2) but it is not going to be installed or
libqt5gui5-gles (>= 5.0.2) but it is not going to be installed
Depends: libqt5quick5 (>= 5.0.2) but it is not going to be installed or
libqt5quick5-gles (>= 5.0.2) but it is not going to be installed
libubuntutoolkit5 : Depends: libqt5gui5 (>= 5.0.2) but it is not going to be installed or
libqt5gui5-gles (>= 5.0.2) but it is not going to be installed
qml-module-io-thp-pyotherside : Depends: libqt5gui5 (>= 5.0.2) but it is not going to be installed or
libqt5gui5-gles (>= 5.0.2) but it is not going to be installed
Depends: libqt5quick5 (>= 5.0.2) but it is not going to be installed or
libqt5quick5-gles (>= 5.0.2) but it is not going to be installed
qml-module-qtquick-layouts : Depends: libqt5gui5 (>= 5.5.0) but it is not going to be installed or
libqt5gui5-gles (>= 5.5.0) but it is not going to be installed
Depends: libqt5quick5 (>= 5.2.0) but it is not going to be installed or
libqt5quick5-gles (>= 5.2.0) but it is not going to be installed
qml-module-ubuntu-layouts : Depends: libqt5quick5 (>= 5.0.2) but it is not going to be installed or
libqt5quick5-gles (>= 5.0.2) but it is not going to be installed
qml-module-ubuntu-performancemetrics : Depends: libqt5gui5 (>= 5.0.2) but it is not going to be installed or
libqt5gui5-gles (>= 5.0.2) but it is not going to be installed
Depends: libqt5quick5 (>= 5.0.2) but it is not going to be installed or
libqt5quick5-gles (>= 5.0.2) but it is not going to be installed
我的第一个问题是,为什么这个包libboost-system1.58.0
与有什么关系qt
?我在 ubuntu 包页面中查找,这些 qt 包既不依赖于libboost-system1.58.0
也不libboost-system1.58.0
依赖于这些 qt 包。
我的第二个问题是,这个包libboost-system1.58.0
真的相关吗?我记得我安装了 boost apt-get install libboost-all-dev
,但显然libboost-system1.58.0
它不在依赖列表中libboost-all-dev
。那么这个包来自哪里?
第三个问题可能与这个问题无关,但是我查看了这些问题qt packages
时,发现它们都有不同版本的重复包,例如:
liboxideqtcore0/xenial-updates,xenial-security,now 1.21.5-0ubuntu0.16.04.1 amd64 [installed,automatic]
liboxideqtcore0/xenial 1.13.6-0ubuntu1 amd64
那么这和我的问题有关吗?
我已经添加了输出apt-cache policy libboost-filesystem1.58.0 liboxideqt-qmlplugin
:
libboost-filesystem1.58.0:
Installed: 1.58.0+dfsg-5ubuntu3.1
Candidate: 1.58.0+dfsg-5ubuntu3.1
Version table:
*** 1.58.0+dfsg-5ubuntu3.1 500
500 http://de.archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages
100 /var/lib/dpkg/status
1.58.0+dfsg-5ubuntu3 500
500 http://de.archive.ubuntu.com/ubuntu xenial/main amd64 Packages
liboxideqt-qmlplugin:
Installed: 1.21.5-0ubuntu0.16.04.1
Candidate: 1.21.5-0ubuntu0.16.04.1
Version table:
*** 1.21.5-0ubuntu0.16.04.1 500
500 http://de.archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages
500 http://security.ubuntu.com/ubuntu xenial-security/main amd64 Packages
100 /var/lib/dpkg/status
1.13.6-0ubuntu1 500
500 http://de.archive.ubuntu.com/ubuntu xenial/main amd64 Packages
答案1
TL;DR。这个问题的简短答案是 - 这是依赖关系问题。所以你不能删除这个包。
分析
libboost-filesystem1.58.0
更长的变体是评估分析以确定安装的原因、哪些包依赖于它以及我们是否可以安全地删除它。
为什么libboost-filesystem1.58.0
和libboost-system1.58.0
被安装
回答第一个问题(为什么) 问题我们可以使用 Aptitude 及其why
命令。
在我全新、完全更新的 Ubuntu MATE 16.04 LTS 上,我得到以下输出
$ aptitude why libboost-filesystem1.58.0 i libmircommon5 Depends libboost-filesystem1.58.0
后者libmircommon5
是由于 LightDM 而安装的:
$ aptitude why libmircommon5 i lightdm Recommends unity-greeter | lightdm-greeter | lightdm-kde-greeter
系统库 -
$ aptitude why libboost-system1.58.0 i libmirclient9 Depends libboost-system1.58.0
在默认使用 Unity 的 Ubuntu 16.04 LTS 上,情况甚至更糟:
$ aptitude why libboost-filesystem1.58.0 i ubuntu-desktop Depends update-notifier i A update-notifier Depends libgtk-3-0 (>= 3.0.0) i A libgtk-3-0 Depends libmirclient9 (>= 0.21.0+16.04.20160330) i A libmirclient9 Depends libmircommon7 (>= 0.26.3+16.04.20170605) i A libmircommon7 Depends libboost-filesystem1.58.0
哪些软件包依赖libboost-filesystem1.58.0
回答第二个问题(哪些依赖项)我们可以使用rdepend
来apt-cache
获取反向依赖项列表(这意味着为什么libboost-filesystem1.58.0
安装了)
$ apt-cache rdepends libboost-filesystem1.58.0 libboost-filesystem1.58.0 Reverse Depends: mir-utils mir-test-tools libboost-log1.58.0 libboost-filesystem1.58-dev juju-mongodb3.2 libmircommon7 vcmi openmw-launcher openmw-cs openmw ycmd witty-examples wesnoth-1.12-server wesnoth-1.12-core undertaker uhd-host ubuntu-location-service-tests ubuntu-location-service-bin tomahawk tmfs thumbnailer-service synfig supercollider-supernova supercollider-language sslsniff ssh-agent-filter springlobby spring sitplus sfftobmp rviz rsbackup rlvm python3-woo python-yade python-woo python-ledger python-fife pulseview progressivemauve pokerth-server pokerth plee-the-bear performous-tools performous pcl-tools orthanc openscad-testing openscad ncmpcpp murasaki-mpi murasaki mupen64plus-video-glide64mk2 mtp-server mrs mongodb-server mongodb-clients mkvtoolnix-gui mkvtoolnix mira-assembler mir-test-tools mia-tools lightspark-common libzeep3.0v5 libyade libwt38 libvolk1-bin liburdf0d libunity-scopes1.0 libunity-scopes-cli libuhd003 libtrust-store2 libthumbnailer-qt1.0 libsdformat4 librviz0d librospack0d libroscpp0d librosbag0d librime1 libqpidcommon2 libpwiz3 libpwiz-tools libpion-plugins libpion-net-plugins libpion-net-dev libpion-dev libpion-common-4.0 libpion-5.0 libpcl-visualization1.7 libpcl-outofcore1.7 libpcl-io1.7 libpam-barada libosl1v5 libopenimageio1.6 libodil0 libnodeletlib0d libmia-2.2-4 libmems-1.6-1v5 libmapnik3.0 liblucene++0v5 libimage-transport0d libgnuradio-wavelet3.7.9 libgnuradio-runtime3.7.9 libgnuradio-fft3.7.9 libgnuradio-fec3.7.9 libgazebo7 libflightcrew0v5 libcollada-urdf0d libcollada-dom2.4-dp0 libcnoid1 libcamera-calibration-parsers0d libboost-log1.58.0 libboost-filesystem1.58-dev libasl0 libaqsis1 lgogdownloader ledger laserboy kcollectd juju-mongodb3.2 juju-mongodb2.6 juju-mongodb innoextract image-transport-tools hugin-tools hhvm gpsshogi gource gnss-sdr gdf-tools gazebo7-plugin-base gazebo7 freeorion freelan esys-particle enfuse enblend dchroot-dsa dchroot dbus-cpp-bin darkradiant-plugins-darkmod darkradiant colobot ckon choreonoid-plugins-base cclive btag bombono-dvd blender bear-factory aqsis aegisub 0ad libdbus-cpp5 schroot libmircommon5 $ apt-cache rdepends libboost-system1.58.0 libboost-system1.58.0 Reverse Depends: mir-utils mir-test-tools mir-demos libboost-wave1.58.0 libboost-system1.58-dev libboost-log1.58.0 libboost-locale1.58.0 libboost-chrono1.58.0 juju-mongodb3.2 ceph-test ceph-mds rbd-nbd rbd-mirror rbd-fuse radosgw mir-platform-graphics-mesa-x12 mir-platform-graphics-mesa-kms12 librgw2 librbd1 libradosstriper1 librados2 librados-dev libmirserver43 libmirplatform15 libmircommon7 libmirclient9 libcephfs1 libcephfs-jni libboost-thread1.58.0 libboost-random1.58.0 libboost-filesystem1.58.0 ceph-fuse ceph-common ceph vcmi openmw-launcher openmw-cs openmw frogatto ycmd witty-examples wesnoth-1.12-server wesnoth-1.12-core voxbo vera++ vdr-plugin-fritzbox unity-system-compositor undertaker uhd-host ubuntu-location-service-tests ubuntu-location-service-bin tophat tomahawk tmfs thumbnailer-service tf2-tools tf-tools synfig supercollider-supernova supercollider-language sslsniff ssh-agent-filter springlobby spring soundscaperenderer-nox soundscaperenderer solarpowerlog snapper sitplus sinfo sfftobmp sdrangelove rviz rsbackup rlvm qutecom qbittorrent-nox qbittorrent python3-woo python3-libtorrent-dbg python3-libtorrent python-yade python-woo python-tf2 python-tf python-rosbag python-rdkit python-libtorrent-dbg python-libtorrent python-libavg python-ledger python-fife pulseview progressivemauve prepair povray pokerth-server pokerth poedit pluginlib-dev plee-the-bear performous-tools performous pcl-tools osm2pgsql orthanc openscad-testing openscad openimageio-tools ogre-1.9-tools ncmpcpp murasaki-mpi murasaki mupen64plus-video-glide64mk2 mtp-server mrs mpikmeans-tools mongodb-server mongodb-clients molds mkvtoolnix-gui mkvtoolnix mira-assembler mir-test-tools mir-platform-graphics-mesa-x8 mir-platform-graphics-mesa-kms8 mia-viewit mia-tools media-hub lightspark-common libzeep3.0v5 libyade libwttest8 libwthttp38 libwtfcgi38 libwtext38 libwtdbo38 libwt38 libvolk1-bin liburdf0d libunity-scopes1.0 libunity-scopes-cli libuhd003 libubuntu-location-service3 libubuntu-download-manager-client1 libtrust-store2 libtorrent-rasterbar8 libtomahawk libthumbnailer-qt1.0 libtf2-ros0d libtf2-0d libtf0d libsnapper2v5 libsfcgal1 libsdformat4 librviz0d librostime0d librospack0d libroslib0d libroscpp0d librosconsole0d librosbag0d librime1 librime-bin librdkit1 librandom-numbers0d libpwiz3 libpwiz-tools libpion-plugins libpion-net-plugins libpion-net-dev libpion-net-4.0 libpion-dev libpion-common-4.0 libpion-5.0 libphonenumber7 libpcl-visualization1.7 libpcl-outofcore1.7 libpcl-io1.7 libpcl-common1.7 libpcl-apps1.7 libpam-barada libosl1v5 liborigin2-1v5 libopenvdb3.1 libopenvdb-tools libopenimageio1.6 libopencv-apps0d libompl10 libogre-1.9.0v5 libodil0 libnodeletlib0d libnodeletlib-tools libnet-cpp2 libmygui.ogreplatform0debian1v5 libmia-2.2-4 libmems-1.6-1v5 libmapnik3.0 liblucene++0v5 liblucene++-contrib0v5 liblaser-geometry0d libkolabxml1v5 libinteractive-markers0d libimage-transport0d libicinga2 libgnuradio-zeromq3.7.9 libgnuradio-wxgui3.7.9 libgnuradio-wavelet3.7.9 libgnuradio-vocoder3.7.9 libgnuradio-video-sdl3.7.9 libgnuradio-uhd3.7.9 libgnuradio-trellis3.7.9 libgnuradio-runtime3.7.9 libgnuradio-rds3.7.0 libgnuradio-qtgui3.7.9 libgnuradio-pmt3.7.9 libgnuradio-pager3.7.9 libgnuradio-osmosdr0.1.4 libgnuradio-noaa3.7.9 libgnuradio-iqbalance0 libgnuradio-hpsdr0 libgnuradio-fosphor3.7.0 libgnuradio-filter3.7.9 libgnuradio-fft3.7.9 libgnuradio-fec3.7.9 libgnuradio-fcdproplus0 libgnuradio-fcd3.7.9 libgnuradio-dtv3.7.9 libgnuradio-digital3.7.9 libgnuradio-comedi3.7.9 libgnuradio-channels3.7.9 libgnuradio-blocks3.7.9 libgnuradio-audio3.7.9 libgnuradio-atsc3.7.9 libgnuradio-analog3.7.9 libgazebo7 libflightcrew0v5 libfield3d1.6 libfcl0 libeiskaltdcpp2.2 libdynamic-reconfigure-config-init-mutex0d libdavix0v5 libcpprest2.8 libcppnetlib0 libcollada-urdf0d libcollada-parser0d libcollada-dom2.4-dp0 libcnoid1 libclass-loader0d libcgal-ipelets libcegui-mk2-0.8.4 libcamera-info-manager0d libcamera-calibration-parsers0d libboost-wave1.58.0 libboost-system1.58-dev libboost-log1.58.0 libboost-locale1.58.0 libboost-chrono1.58.0 libbondcpp0d libasl0 libaqsis1 libair-modes0v5 libadolc2 libactionlib0d lgogdownloader ledger laserboy krita kicad kcollectd juju-mongodb3.2 juju-mongodb2.6 juju-mongodb innoextract image-transport-tools icinga2-studio icinga2-ido-pgsql icinga2-ido-mysql icinga2-bin hugin-tools hhvm guitarix gr-rds gr-osmosdr gr-iqbal gr-hpsdr gr-fosphor gr-fcdproplus gr-air-modes gqrx-sdr gpsshogi gource gnuradio gnss-sdr glob2 gdf-tools gazebo7-plugin-base gazebo7 funguloids freeorion freelan freecad flamerobin field3d-bin esys-particle enfuse enblend eiskaltdcpp-qt-mini eiskaltdcpp-qt eiskaltdcpp-gtk3 eiskaltdcpp-gtk eiskaltdcpp-daemon dssp dchroot-dsa dchroot dbus-cpp-bin darkradiant-plugins-darkmod darkradiant colobot ckon choreonoid-plugins-base ceph-test ceph-mds cclive btfs btag bombono-dvd blender bear-factory autodock-vina aqsis anytun amule-utils-gui amule-utils amule-daemon amule aegisub ceph schroot rbd-nbd rbd-mirror rbd-fuse radosgw librgw2 librbd1 libradosstriper1 librados2 librados-dev liborcus-0.10-0v5 libmirserver38 libmirplatform11 libmircommon5 libmirclient9 libixion-0.10-0v5 libdbus-cpp5 libcephfs1 libcephfs-jni libboost-thread1.58.0 libboost-random1.58.0 libboost-filesystem1.58.0 ceph-fuse ceph-common
我可以删除libboost-filesystem1.58.0
并像以前一样使用该系统吗?
那么它可以被移除吗?让我们使用 MATE 在系统上运行它的移除模拟:
$ apt-get remove --simulate libboost-filesystem1.58.0 NOTE: This is only a simulation! apt-get needs root privileges for real execution. Keep also in mind that locking is deactivated, so don't depend on the relevance to the real current situation! Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: freepats libcapnp-0.5.3 libde265-0 libfluidsynth1 libgtkglext1 libmimic0 libmircore1 libmjpegutils-2.1-0 libmms0 libmpeg2encpp-2.1-0 libmplex2-2.1-0 libofa0 libopenal-data libopenal1 libopencv-calib3d2.4v5 libopencv-contrib2.4v5 libopencv-features2d2.4v5 libopencv-flann2.4v5 libopencv-highgui2.4v5 libopencv-legacy2.4v5 libopencv-ml2.4v5 libopencv-objdetect2.4v5 libopencv-video2.4v5 libsoundtouch1 libspandsp2 libsrtp0 libvo-aacenc0 libvo-amrwbenc0 libwebpdemux1 libwildmidi-config libwildmidi1 libxfont2 libzbar0 Use 'apt autoremove' to remove them. The following packages will be REMOVED: a11y-profile-manager-indicator account-plugin-facebook account-plugin-flickr account-plugin-google adwaita-icon-theme apport-gtk apturl atril bamfdaemon blueman brasero brasero-cdrkit caja cheese compiz compiz-gnome compiz-mate dconf-editor deja-dup deja-dup-backend-cloudfiles deja-dup-backend-gvfs deja-dup-backend-s3 deja-dup-caja firefox folder-color-caja galculator gcr gdebi gir1.2-appindicator3-0.1 gir1.2-gtk-3.0 gir1.2-peas-1.0 gir1.2-rb-3.0 gir1.2-vte-2.91 gir1.2-webkit-3.0 gir1.2-webkit2-4.0 gir1.2-wnck-3.0 gnome-disk-utility gnome-icon-theme gnome-icon-theme-symbolic gnome-keyring gnome-orca gnome-session-canberra gnome-system-tools gstreamer1.0-clutter-3.0 gstreamer1.0-plugins-bad gstreamer1.0-plugins-bad-faad gstreamer1.0-plugins-bad-videoparsers gucharmap gufw gvfs-backends humanity-icon-theme indicator-application indicator-application-gtk2 language-selector-gnome libaccount-plugin-1.0-0 libaccount-plugin-generic-oauth libaccount-plugin-google libappindicator3-1 libatrilview3 libboost-filesystem1.58.0 libbrasero-media3-1 libcanberra-gtk3-0 libcanberra-gtk3-module libcheese-gtk25 libcheese8 libclutter-1.0-0 libclutter-gst-3.0-0 libclutter-gtk-1.0-0 libcogl-pango20 libcogl-path20 libcogl20 libegl1-mesa libgcr-ui-3-1 libgnome-desktop-3-12 libgstreamer-plugins-bad1.0-0 libgtk-3-0 libgtk-3-bin libgtk-3-common libgucharmap-2-90-7 libido3-0.1-0 libindicator3-7 libkeybinder-3.0-0 libmetacity-private3a libmirclient9 libmircommon5 libmircommon7 libnautilus-extension1a libnm-gtk0 libnma0 libpeas-1.0-0 libpeas-1.0-0-python3loader libplank1 libqt5gui5 libqt5libqgtk2 libqt5widgets5 libqt5x11extras5 libreoffice-avmedia-backend-gstreamer librhythmbox-core9 libtopmenu-client-gtk3-0 libtopmenu-server-gtk3-0 libunity-control-center1 libvte-2.91-0 libwayland-egl1-mesa libwebkit2gtk-4.0-37 libwebkitgtk-1.0-0 libwebkitgtk-3.0-0 libwnck-3-0 libyelp0 lightdm-gtk-greeter lightdm-gtk-greeter-settings marco mate-applet-topmenu mate-applets mate-control-center mate-desktop mate-desktop-environment-core mate-dock-applet mate-gnome-main-menu-applet mate-indicator-applet mate-panel mate-screensaver mate-session-manager mate-tweak mate-user-guide network-manager-gnome network-manager-pptp-gnome onboard onboard-data pinentry-gnome3 plank python3-aptdaemon.gtk3widgets rhythmbox rhythmbox-plugin-cdrecorder rhythmbox-plugins seahorse sessioninstaller shotwell simple-scan software-properties-gtk synapse system-config-printer-gnome thunderbird thunderbird-locale-en thunderbird-locale-en-us tilda topmenu-gtk3 transmission-gtk ubuntu-mate-artwork ubuntu-mate-default-settings ubuntu-mate-icon-themes ubuntu-mate-lightdm-theme ubuntu-mate-themes ubuntu-mate-welcome ubuntu-mono ubuntu-release-upgrader-gtk unity-asset-pool update-manager update-notifier usb-creator-gtk vlc xdg-user-dirs-gtk xorg xserver-xorg-core-hwe-16.04 xserver-xorg-hwe-16.04 xserver-xorg-input-all-hwe-16.04 xserver-xorg-input-evdev-hwe-16.04 xserver-xorg-input-synaptics-hwe-16.04 xserver-xorg-input-wacom-hwe-16.04 xserver-xorg-video-all-hwe-16.04 xserver-xorg-video-amdgpu-hwe-16.04 xserver-xorg-video-ati-hwe-16.04 xserver-xorg-video-fbdev-hwe-16.04 xserver-xorg-video-intel-hwe-16.04 xserver-xorg-video-nouveau-hwe-16.04 xserver-xorg-video-qxl-hwe-16.04 xserver-xorg-video-radeon-hwe-16.04 xserver-xorg-video-vesa-hwe-16.04 xserver-xorg-video-vmware-hwe-16.04 xul-ext-lightning yelp zenity 0 upgraded, 0 newly installed, 181 to remove and 0 not upgraded.
上述意味着如果我们删除该libboost-filesystem1.58.0
包,我们将失去桌面环境和整个 X11 系统。
基于 Unity 的系统的模拟以您问题中的错误结束。
答案2
问题可能出在 apt 源列表中,请参阅以下步骤:https://icinga.com/docs/icinga-2/latest/doc/02-installation/02-Ubuntu/
apt-get update
apt-get -y install apt-transport-https wget gnupg
wget -O - https://packages.icinga.com/icinga.key | apt-key add -
. /etc/os-release; if [ ! -z ${UBUNTU_CODENAME+x} ]; then DIST="${UBUNTU_CODENAME}"; else DIST="$(lsb_release -c| awk '{print $2}')"; fi; \
echo "deb https://packages.icinga.com/ubuntu icinga-${DIST} main" > \
/etc/apt/sources.list.d/${DIST}-icinga.list
echo "deb-src https://packages.icinga.com/ubuntu icinga-${DIST} main" >> \
/etc/apt/sources.list.d/${DIST}-icinga.list